@Test(expected = ResourceNotFoundException.class)
public void testGetFlowsByBucketDoesNotExist() {

    when(metadataService.getBucketById(any(String.class))).thenReturn(null);
    registryService.getFlows("b1");
}