private void checkVolumesExist() {
        final List<IndexVolume> indexVolumes = indexVolumeGroupService.getNames()
                .parallelStream()
                .flatMap(groupName -> indexVolumeService.find(new ExpressionCriteria()).stream())
                .collect(Collectors.toList());

        LOGGER.info("Checking available index volumes, found:\n{}",
                indexVolumes.stream()
                        .map(IndexVolume::getPath)
                        .collect(Collectors.joining("\n")));

        final List<FsVolume> dataVolumes = fsVolumeService.find(FindFsVolumeCriteria.matchAll()).getValues();
        LOGGER.info("Checking available data volumes, found:\n{}",
                dataVolumes.stream()
                        .map(FsVolume::getPath)
                        .collect(Collectors.joining("\n")));

        if (dataVolumes.isEmpty() || indexVolumes.isEmpty()) {
            LOGGER.error("Missing volumes, quiting");
            System.exit(1);
        }
    }
Script to create some base data for testing.
stroom-app/src/test/java/stroom/test/SetupSampleDataBean.java