From 68c343902adfe3206c50135cf8228d830526a9fa Mon Sep 17 00:00:00 2001 From: Ken Stevens Date: Wed, 31 Aug 2022 22:46:17 -0400 Subject: [PATCH] jpa test split (#3959) * create fhir-version specific hapi-fhir-jpaserver-test projects * moved dstu2 tests out to dstu2 test project. * moved dstu2 tests out to dstu2 test project. * finished moving dstu2 tests out to dstu2 test project. * finished moving dstu2 tests out to dstu2 test project. * dstu3 test project compiles * start moving dstu3 resources * letting azure pileine know about the new modules * finished moving dstu3 resources. this might pass * OK this one should pass for sure * OK this one should pass for sure * change test poms to test scope * move the rest of R4 test classes * move the rest of R4 test classes * moar r4 moves * moar r4 moves * moar r4 moves * finished with r4 * finished with r4 * started r5 * started r5 * Cache busting based on source branch name * Fix other cache key * cache pegged to SHa1 * test cleanup Co-authored-by: Ken Stevens Co-authored-by: markiantorno Co-authored-by: Tadgh --- azure-pipelines.yml | 26 +- hapi-fhir-jacoco/pom.xml | 21 ++ hapi-fhir-jpaserver-test-dstu2/pom.xml | 113 +++++++++ .../jpa/config/min/ResourceMinimizerMojo.java | 8 +- .../jpa/dao/dstu2/BaseJpaDstu2SystemTest.java | 0 .../fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java | 17 +- ...ceDaoDstu2SearchCustomSearchParamTest.java | 1 - .../FhirResourceDaoDstu2SearchFtTest.java | 34 +-- .../FhirResourceDaoDstu2SearchNoFtTest.java | 0 .../dao/dstu2/FhirResourceDaoDstu2Test.java | 4 +- .../dstu2/FhirResourceDaoDstu2UpdateTest.java | 0 .../FhirResourceDaoDstu2ValidateTest.java | 0 .../FhirResourceDaoValueSetDstu2Test.java | 0 .../jpa/dao/dstu2/FhirSearchDaoDstu2Test.java | 2 - .../dstu2/FhirSystemDaoDstu2SearchTest.java | 3 - .../jpa/dao/dstu2/FhirSystemDaoDstu2Test.java | 0 .../BaseResourceProviderDstu2Test.java | 0 .../QuestionnaireResourceProviderDstu2.java | 0 .../provider/ResourceProviderDstu2Test.java | 0 .../ResourceProviderDstu2ValueSetTest.java | 0 .../ResourceProviderExpungeDstu2Test.java | 2 - .../jpa/provider/SubscriptionsDstu2Test.java | 0 .../jpa/provider/SystemProviderDstu2Test.java | 0 ...temProviderTransactionSearchDstu2Test.java | 0 .../ca/uhn/fhir/jpa/search/BaseSearchSvc.java | 0 .../search/SearchCoordinatorSvcImplTest.java | 0 .../search/SynchronousSearchSvcImplTest.java | 0 .../fhir/jpa/subscription/FhirDstu2Util.java | 14 +- .../email/EmailSubscriptionDstu2Test.java | 4 +- .../resthook/RestHookTestDstu2Test.java | 2 +- ...rceptorRegisteredToDaoConfigDstu2Test.java | 2 +- .../WebsocketWithCriteriaDstu2Test.java | 6 +- .../WebsocketWithSubscriptionIdDstu2Test.java | 6 +- .../jpa/term/TerminologySvcImplDstu2Test.java | 0 .../uhn/fhir/jpa/z/ResourceMinimizerMojo.java | 8 +- .../ValidatorAcrossVersionsTest.java | 0 .../allergyintolerance-sd-david.json | 0 .../resources/binu_testpatient_resource.json | 0 ..._testpatient_structuredefinition_dstu2.xml | 0 .../src/test/resources/bug147-bundle.json | 0 .../src/test/resources/bug638.xml | 0 .../src/test/resources/document-father.json | 0 .../resources/dstu2/Conformance-server.json | 0 .../resources/dstu2/createdeletebundle.json | 0 .../src/test/resources/extensional-case-2.xml | 0 .../issue534/bw_profile_snapshot.xml | 0 .../resources/issue534/example_profile.xml | 0 .../resources/issue534/fiphr-vs-bodysite.xml | 0 .../issue534/fiphr-vs-observationmethod.xml | 0 hapi-fhir-jpaserver-test-dstu3/pom.xml | 113 +++++++++ .../jpa/dao/dstu3/BaseJpaDstu3SystemTest.java | 0 .../jpa/dao/dstu3/CustomObservationDstu3.java | 5 +- .../dstu3/FhirDaoConcurrencyDstu3Test.java | 0 .../FhirResourceDaoCustomTypeDstu3Test.java | 0 .../FhirResourceDaoDocumentDstu3Test.java | 0 .../FhirResourceDaoDstu3CodeSystemTest.java | 0 .../FhirResourceDaoDstu3ConceptMapTest.java | 0 .../FhirResourceDaoDstu3ContainedTest.java | 0 ...ResourceDaoDstu3ExternalReferenceTest.java | 0 ...esourceDaoDstu3PhoneticSearchNoFtTest.java | 0 ...ourceDaoDstu3ReferentialIntegrityTest.java | 0 ...ceDaoDstu3SearchCustomSearchParamTest.java | 0 ...hirResourceDaoDstu3SearchDistanceTest.java | 22 +- .../FhirResourceDaoDstu3SearchFtTest.java | 3 +- .../FhirResourceDaoDstu3SearchNoFtTest.java | 0 .../FhirResourceDaoDstu3SearchSqlTest.java | 0 .../dstu3/FhirResourceDaoDstu3SourceTest.java | 2 +- ...sourceDaoDstu3StructureDefinitionTest.java | 0 .../FhirResourceDaoDstu3TerminologyTest.java | 0 .../dao/dstu3/FhirResourceDaoDstu3Test.java | 11 +- .../dstu3/FhirResourceDaoDstu3UpdateTest.java | 4 +- .../FhirResourceDaoDstu3ValidateTest.java | 0 ...ourceDaoDstu3ValueSetMultiVersionTest.java | 0 .../FhirResourceDaoDstu3ValueSetTest.java | 0 .../jpa/dao/dstu3/FhirSearchDaoDstu3Test.java | 21 +- .../jpa/dao/dstu3/FhirSystemDaoDstu3Test.java | 9 +- .../FhirSystemDaoTransactionDstu3Test.java | 0 .../fhir/jpa/dao/expunge/ExpungeHookTest.java | 72 +++--- .../jpa/packages/IgInstallerDstu3Test.java | 4 +- .../uhn/fhir/jpa/packages/NpmDstu3Test.java | 0 .../dstu3/BaseResourceProviderDstu3Test.java | 2 +- .../dstu3/CompositionDocumentDstu3Test.java | 0 .../jpa/provider/dstu3/CorsDstu3Test.java | 9 +- .../dstu3/GraphQLProviderDstu3Test.java | 11 +- .../dstu3/PatientEverythingDstu3Test.java | 0 .../QuestionnaireResourceProviderDstu3.java | 0 ...rceProviderCustomSearchParamDstu3Test.java | 0 .../ResourceProviderDeleteSqlDstu3Test.java | 0 .../ResourceProviderDstu3BundleTest.java | 5 - .../ResourceProviderDstu3CodeSystemTest.java | 0 ...eProviderDstu3CodeSystemVersionedTest.java | 0 .../ResourceProviderDstu3ConceptMapTest.java | 0 .../ResourceProviderDstu3DistanceTest.java | 30 +-- ...eProviderDstu3StructureDefinitionTest.java | 2 - .../dstu3/ResourceProviderDstu3Test.java | 3 +- .../ResourceProviderDstu3ValueSetTest.java | 3 +- ...rceProviderDstu3ValueSetVersionedTest.java | 0 .../ResourceProviderExpungeDstu3Test.java | 0 ...roviderQuestionnaireResponseDstu3Test.java | 3 +- ...ceProviderR3CodeSystemDesignationTest.java | 0 ...sourceProviderSearchModifierDstu3Test.java | 5 - .../jpa/provider/dstu3/ServerDstu3Test.java | 0 .../dstu3/SubscriptionsDstu3Test.java | 0 ...temProviderTransactionSearchDstu3Test.java | 0 .../PagingMultinodeProviderDstu3Test.java | 0 .../jpa/searchparam/MatchUrlServiceTest.java | 0 .../fhir/jpa/subscription/FhirDstu3Util.java | 12 +- .../email/EmailSenderImplTest.java | 0 .../email/EmailSubscriptionDstu3Test.java | 4 +- .../resthook/RestHookTestDstu3Test.java | 32 +-- ...rceptorRegisteredToDaoConfigDstu3Test.java | 0 .../SubscriptionTriggeringDstu3Test.java | 0 .../WebsocketWithCriteriaDstu3Test.java | 9 +- .../WebsocketWithSubscriptionIdDstu3Test.java | 0 ...minologyLoaderSvcIntegrationDstu3Test.java | 18 +- .../jpa/term/TerminologySvcImplDstu3Test.java | 2 +- .../fhir/validator/AttachmentUtilTest.java | 0 .../src/test/resources/batch-error.xml | 0 .../src/test/resources}/bug-410-bundle.xml | 3 +- .../src/test/resources/bug1044-bundle.xml | 0 .../test/resources/bug147-bundle-dstu3.json | 0 .../src/test/resources/bundle-dstu3.xml | 0 .../test/resources/document-bundle-dstu3.json | 0 .../test/resources/document-father-dstu3.json | 0 .../resources/dstu3/Reilly_Libby_73.json.gz | Bin .../src/test/resources/dstu3/bundle.json | 0 .../dstu3/duplicate-conditional-create.json | 0 .../resources/dstu3/fmc01-cs-yesnounk.json | 0 .../dstu3/fmc03-cs-binderrecommend.json | 0 .../resources/dstu3/fmc03-questionnaire.json | 0 .../dstu3/fmc03-questionnaireresponse.json | 0 .../dstu3/fmc03-vs-binderrecommend.json | 0 .../resources/dstu3/fmc03-vs-fmcyesno.json | 0 .../iar/CodeSystem-iar-citizenship-status.xml | 0 .../iar/ValueSet-iar-citizenship-status.xml | 0 ...4.3.11.60.40.2.20.5.2--20171231000000.json | 0 .../no-store-header/episodeofcare-bundle.json | 0 .../no-store-header/location-bundle.json | 0 .../no-store-header/organization-bundle.json | 0 .../dstu3/no-store-header/patient-bundle.json | 0 .../no-store-header/practitioner-bundle.json | 0 .../profile-differential-patient-dstu3.json | 0 .../src/test/resources/dstu3/slow_bundle.xml | 0 .../resources/dstu3_codesystem_complete.json | 0 .../dstu3_custom_resource_patient.json | 0 .../src/test/resources/dstu3_transaction2.xml | 0 .../test/resources/mihin-resource-dstu3.json | 0 .../src/test/resources/oruBundle.json | 0 .../nictiz.fhir.nl.stu3.zib2017-1.3.10.tgz | Bin .../nictiz.fhir.nl.stu3.zib2017-1.3.9.tgz | Bin .../packages/nictiz.fhir.nl.stu3.zib2017.json | 0 .../test/resources/questionnaire_dstu3.xml | 0 .../src/test/resources/sd-david-dhtest7.json | 0 hapi-fhir-jpaserver-test-r4/pom.xml | 113 +++++++++ .../ClientThreadedCapabilitiesTest.java | 1 - .../fhir/jpa/batch2/Batch2CoordinatorIT.java | 2 +- .../jpa/batch2/JobInstanceRepositoryTest.java | 0 .../jpa/batch2/JpaJobPersistenceImplTest.java | 0 .../binstore/BinaryAccessProviderTest.java | 9 +- .../DatabaseBlobBinaryStorageSvcImplTest.java | 0 .../FilesystemBinaryStorageSvcImplTest.java | 5 +- .../NullBinaryStorageSvcImplTest.java | 0 .../jpa/bulk/BulkDataExportProviderTest.java | 0 .../bulk/imprt/svc/BulkDataImportR4Test.java | 0 .../imprt/svc/BulkDataImportSvcImplTest.java | 0 .../jpa/bulk/imprt2/BulkImportR4Test.java | 0 .../bulk/imprt2/ConsumeFilesStepR4Test.java | 0 .../ResourceChangeListenerRegistryImplIT.java | 2 +- .../cache/ResourceVersionCacheSvcTest.java | 2 +- .../uhn/fhir/jpa/dao/BaseHapiFhirDaoTest.java | 0 .../jpa/dao/BaseHapiFhirResourceDaoTest.java | 1 - ...ersistedResourceValidationSupportTest.java | 3 - .../jpa/dao/TolerantJsonParserR4Test.java | 0 .../jpa/dao/TransactionProcessorTest.java | 0 .../jpa/dao/expunge/DeleteExpungeDaoTest.java | 0 .../expunge/ResourceTableFKProviderTest.java | 0 .../jpa/dao/index/IdHelperServiceTest.java | 6 +- .../jpa/dao/r4/BaseComboParamsR4Test.java | 0 .../fhir/jpa/dao/r4/BaseJpaR4SystemTest.java | 0 .../jpa/dao/r4/BasePartitioningR4Test.java | 0 .../fhir/jpa/dao/r4/ChainingR4SearchTest.java | 0 .../jpa/dao/r4/ConsentEventsDaoR4Test.java | 2 +- .../fhir/jpa/dao/r4/CustomObservationR4.java | 5 +- ...irResourceDaoCreatePlaceholdersR4Test.java | 0 .../r4/FhirResourceDaoCustomTypeR4Test.java | 0 .../dao/r4/FhirResourceDaoDocumentR4Test.java | 0 .../r4/FhirResourceDaoR4CacheWarmingTest.java | 1 - .../r4/FhirResourceDaoR4CodeSystemTest.java | 0 ...rResourceDaoR4ComboNonUniqueParamTest.java | 0 .../FhirResourceDaoR4ComboUniqueParamIT.java | 4 +- .../r4/FhirResourceDaoR4ConceptMapTest.java | 0 .../FhirResourceDaoR4ConcurrentWriteTest.java | 0 .../r4/FhirResourceDaoR4ContainedTest.java | 0 .../dao/r4/FhirResourceDaoR4CreateTest.java | 2 +- .../dao/r4/FhirResourceDaoR4DeleteTest.java | 0 ...hirResourceDaoR4ExternalReferenceTest.java | 18 +- .../dao/r4/FhirResourceDaoR4FilterTest.java | 0 .../FhirResourceDaoR4HistoryRewriteTest.java | 0 ...irResourceDaoR4InlineResourceModeTest.java | 0 .../r4/FhirResourceDaoR4InterceptorTest.java | 0 ...rResourceDaoR4InvalidSubscriptionTest.java | 2 +- .../jpa/dao/r4/FhirResourceDaoR4MetaTest.java | 0 .../r4/FhirResourceDaoR4QueryCountTest.java | 0 ...ResourceDaoR4ReferentialIntegrityTest.java | 0 ...ourceDaoR4SearchCustomSearchParamTest.java | 0 .../FhirResourceDaoR4SearchDistanceTest.java | 42 ++-- .../dao/r4/FhirResourceDaoR4SearchFtTest.java | 0 .../FhirResourceDaoR4SearchIncludeTest.java | 0 .../FhirResourceDaoR4SearchMissingTest.java | 0 .../r4/FhirResourceDaoR4SearchNoFtTest.java | 0 .../FhirResourceDaoR4SearchNoHashesTest.java | 0 .../FhirResourceDaoR4SearchOptimizedTest.java | 0 ...FhirResourceDaoR4SearchPageExpiryTest.java | 0 .../r4/FhirResourceDaoR4SearchSqlTest.java | 0 ...rceDaoR4SearchWithHSearchDisabledTest.java | 0 .../FhirResourceDaoR4SelectiveUpdateTest.java | 0 .../jpa/dao/r4/FhirResourceDaoR4SortTest.java | 0 .../dao/r4/FhirResourceDaoR4SourceTest.java | 2 +- ...rResourceDaoR4StandardQueriesNoFTTest.java | 0 ...rResourceDaoR4StructureDefinitionTest.java | 0 .../jpa/dao/r4/FhirResourceDaoR4TagsTest.java | 0 .../r4/FhirResourceDaoR4TerminologyTest.java | 169 +++++++------ .../jpa/dao/r4/FhirResourceDaoR4Test.java | 0 ...hirResourceDaoR4UpdateTagSnapshotTest.java | 0 .../dao/r4/FhirResourceDaoR4UpdateTest.java | 0 .../dao/r4/FhirResourceDaoR4ValidateTest.java | 0 ...ResourceDaoR4ValueSetMultiVersionTest.java | 4 +- .../dao/r4/FhirResourceDaoR4ValueSetTest.java | 0 ...irResourceDaoR4VersionedReferenceTest.java | 0 .../dao/r4/FhirResourceDaoSearchListTest.java | 0 .../FhirResourceDaoSearchParameterR4Test.java | 0 .../fhir/jpa/dao/r4/FhirSearchDaoR4Test.java | 0 .../jpa/dao/r4/FhirSystemDaoR4SearchTest.java | 3 - .../fhir/jpa/dao/r4/FhirSystemDaoR4Test.java | 11 +- .../uhn/fhir/jpa/dao/r4/JpaHistoryR4Test.java | 0 ...itioningNonNullDefaultPartitionR4Test.java | 1 - .../dao/r4/PartitioningSearchCacheR4Test.java | 1 - .../jpa/dao/r4/PartitioningSqlR4Test.java | 0 .../dao/r4/SearchCoordinatorSvcImplTest.java | 2 - .../dao/r4/SearchParamExtractorR4Test.java | 0 .../jpa/dao/r4/SearchParameterMapTest.java | 2 - .../dao/r4/SearchWithInterceptorR4Test.java | 0 .../uhn/fhir/jpa/dao/r4/SyntheaPerfTest.java | 0 .../uhn/fhir/jpa/dao/r4/TestContextLoads.java | 0 .../jpa/dao/r4/TransactionDeleteR4Test.java | 2 +- .../fhir/jpa/dao/r4/TransactionHookTest.java | 0 .../delete/DeleteConflictServiceR4Test.java | 0 .../jpa/delete/job/DeleteExpungeJobTest.java | 0 .../fhir/jpa/delete/job/ReindexJobTest.java | 0 .../jpa/delete/job/ReindexTestHelper.java | 0 ...DaoRegistryGraphQLStorageServicesTest.java | 19 +- .../CascadingDeleteInterceptorTest.java | 0 .../ForceOffsetSearchModeInterceptorTest.java | 0 ...ialIntegrityForDeletesInterceptorTest.java | 2 +- .../PartitioningInterceptorR4Test.java | 2 - .../PatientIdPartitionInterceptorTest.java | 0 ...TerminologyTranslationInterceptorTest.java | 0 ...earchPreferHandlingInterceptorJpaTest.java | 11 - ...sitoryValidatingInterceptorHttpR4Test.java | 2 +- ...RepositoryValidatingInterceptorR4Test.java | 0 ...tionMessageSuppressingInterceptorTest.java | 0 .../jpa/packages/JpaPackageCacheTest.java | 4 +- .../ca/uhn/fhir/jpa/packages/NpmR4Test.java | 102 +++----- .../fhir/jpa/packages/NpmSearchR4Test.java | 0 .../packages/PackageInstallerSvcImplTest.java | 0 .../PartitionManagementProviderTest.java | 1 - .../PartitionSettingsSvcImplTest.java | 2 +- ...rtitionedSubscriptionTriggeringR4Test.java | 24 +- .../RequestPartitionHelperSvcTest.java | 0 .../fhir/jpa/patch/FhirPatchApplyR4Test.java | 0 .../fhir/jpa/patch/FhirPatchDiffR4Test.java | 0 .../jpa/provider/GraphQLR4ProviderTest.java | 22 +- .../TerminologyUploaderProviderTest.java | 0 .../r4/AuthorizationInterceptorJpaR4Test.java | 18 +- ...zationInterceptorMultitenantJpaR4Test.java | 0 ...BaseMultitenantResourceProviderR4Test.java | 0 .../r4/BinaryAccessProviderR4Test.java | 0 .../r4/BinaryStorageInterceptorR4Test.java | 2 +- .../r4/CompositionDocumentR4Test.java | 0 ...sentInterceptorResourceProviderR4Test.java | 0 .../uhn/fhir/jpa/provider/r4/CorsR4Test.java | 9 +- .../jpa/provider/r4/DiffProviderR4Test.java | 86 +++---- .../jpa/provider/r4/EmptyIndexesR4Test.java | 2 +- .../fhir/jpa/provider/r4/ExpungeR4Test.java | 0 .../fhir/jpa/provider/r4/GraphQLR4Test.java | 4 +- .../provider/r4/HookInterceptorR4Test.java | 0 .../r4/MemberMatcherR4HelperTest.java | 0 .../r4/MultitenantBatchOperationR4Test.java | 23 +- .../provider/r4/MultitenantServerR4Test.java | 0 .../jpa/provider/r4/NicknameSearchR4Test.java | 0 .../r4/OpenApiInterceptorJpaTest.java | 0 .../jpa/provider/r4/PatchProviderR4Test.java | 0 .../provider/r4/PatientEverythingR4Test.java | 0 .../r4/PatientMemberMatchOperationR4Test.java | 0 .../r4/QuestionnaireResourceProviderR4.java | 2 +- ...minologyServiceResourceProviderR4Test.java | 0 .../r4/ResourceProviderConcurrencyR4Test.java | 0 ...sourceProviderCustomSearchParamR4Test.java | 0 .../r4/ResourceProviderExpungeR4Test.java | 0 .../r4/ResourceProviderHasParamR4Test.java | 0 .../r4/ResourceProviderInterceptorR4Test.java | 0 .../r4/ResourceProviderInvalidDataR4Test.java | 0 ...oviderOnlySomeResourcesProvidedR4Test.java | 0 ...ceProviderQuestionnaireResponseR4Test.java | 0 .../r4/ResourceProviderR4BundleTest.java | 0 .../r4/ResourceProviderR4CacheTest.java | 0 ...ceProviderR4CodeSystemDesignationTest.java | 0 .../r4/ResourceProviderR4CodeSystemTest.java | 6 +- ...urceProviderR4CodeSystemVersionedTest.java | 14 +- .../r4/ResourceProviderR4ConceptMapTest.java | 0 .../r4/ResourceProviderR4DistanceTest.java | 30 +-- ...sourceProviderR4RemoteTerminologyTest.java | 0 ...ResourceProviderR4SearchContainedTest.java | 0 ...urceProviderR4StructureDefinitionTest.java | 0 .../provider/r4/ResourceProviderR4Test.java | 1 - ...ProviderR4ValueSetHSearchDisabledTest.java | 0 ...rceProviderR4ValueSetNoVerCSNoVerTest.java | 2 - ...ourceProviderR4ValueSetVerCSNoVerTest.java | 2 - ...esourceProviderR4ValueSetVerCSVerTest.java | 2 - .../ResourceProviderSearchModifierR4Test.java | 0 .../r4/ResourceProviderSummaryModeR4Test.java | 2 - ...rCapabilityStatementProviderJpaR4Test.java | 0 .../fhir/jpa/provider/r4/ServerR4Test.java | 0 .../r4/StaleSearchDeletingSvcR4Test.java | 0 .../jpa/provider/r4/SubscriptionsR4Test.java | 0 .../jpa/provider/r4/SystemProviderR4Test.java | 3 +- ...SystemProviderTransactionSearchR4Test.java | 2 +- .../r4/TerminologyUploaderProviderR4Test.java | 0 .../uhn/fhir/jpa/reindex/ReindexStepTest.java | 2 +- .../reindex/ResourceReindexSvcImplTest.java | 0 ...ExtendedHSearchResourceProjectionTest.java | 4 +- .../r4/PagingMultinodeProviderR4Test.java | 0 .../ResourceReindexingSvcImplTest.java | 2 +- .../stresstest/GiantTransactionPerfTest.java | 0 .../ca/uhn/fhir/jpa/stresstest/README.txt | 0 .../jpa/stresstest/StressTestParserTest.java | 0 .../fhir/jpa/stresstest/StressTestR4Test.java | 0 .../subscription/BaseSubscriptionsR4Test.java | 0 .../uhn/fhir/jpa/subscription/FhirR4Util.java | 7 +- ...SubscriptionValidatingInterceptorTest.java | 1 - .../InMemorySubscriptionMatcherR4Test.java | 12 +- ...tivatesPreExistingSubscriptionsR4Test.java | 2 +- .../resthook/RestHookTestR4Test.java | 0 ...nterceptorRegisteredToDaoConfigR4Test.java | 4 +- .../RestHookWithEventDefinitionR4Test.java | 0 .../RestHookWithInterceptorR4Test.java | 2 +- .../WebsocketWithCriteriaR4Test.java | 9 +- .../WebsocketWithSubscriptionIdR4Test.java | 2 +- .../ca/uhn/fhir/jpa/term/BaseLoaderTest.java | 0 .../ca/uhn/fhir/jpa/term/BaseTermR4Test.java | 2 +- .../uhn/fhir/jpa/term/ITermReadSvcTest.java | 0 .../term/TermCodeSystemStorageSvcTest.java | 0 .../term/TermConceptMappingSvcImplTest.java | 2 - .../jpa/term/TermVersionAdapterSvcR4Test.java | 0 .../term/TerminologyLoaderSvcCustomTest.java | 4 +- .../TerminologyLoaderSvcIcd10cmJpaTest.java | 3 +- .../term/TerminologyLoaderSvcImgthlaTest.java | 2 +- .../TerminologyLoaderSvcLoincJpaTest.java | 14 +- .../term/TerminologyLoaderSvcLoincTest.java | 176 ++----------- .../TerminologyLoaderSvcSnomedCtTest.java | 6 +- .../jpa/term/TerminologySvcDeltaR4Test.java | 2 +- ...erminologySvcImplCurrentVersionR4Test.java | 9 +- .../jpa/term/TerminologySvcImplR4Test.java | 0 .../jpa/term/ValueSetExpansionR4Test.java | 56 +++-- .../ValueSetHSearchExpansionR4LuceneIT.java | 0 .../ReindexTerminologyHSearchR4Test.java | 0 .../term/job/TermCodeSystemDeleteJobTest.java | 9 +- .../TermCodeSystemVersionDeleteJobTest.java | 9 +- .../jpa/term/loinc/BaseLoincHandlerTest.java | 0 .../uhn/fhir/jpa/util/ValueSetTestUtil.java | 0 .../util/jsonpatch/JsonPatchUtilsTest.java | 2 +- .../src/test/resources/dstu3-person.json | 0 .../duplicate-conditional-create.json | 0 .../src/test/resources/imgthla/bogus.txt | 0 .../src/test/resources/imgthla/hla.xml | 0 .../src/test/resources/imgthla/hla_nom.txt | 0 .../resources/largecodesystem/ValueSetV.json | 0 .../resources/largecodesystem/ValueSetV1.json | 0 .../resources/largecodesystem/concepts.csv | 0 .../resources/largecodesystem/hierarchy.csv | 0 .../largecodesystem/observation-matching.json | 0 .../observation-non-matching.json | 0 .../loinc-reindex/Loinc_small_v68.zip | Bin .../loinc-reindex/v268_loincupload.properties | 0 .../test/resources/npe-causing-bundle.json | 0 .../packages/de.basisprofil.r4-1.2.0.tgz | Bin ...eSystem-iar-chymh-cb-calculated-cap-10.xml | 0 .../test/resources/r4/ConceptMap-icd-sct.xml | 0 ...uctureDefinition-kfdrc-patient-no-phi.json | 0 .../r4/StructureDefinition-kfdrc-patient.json | 0 ...alueSet-iar-chymh-cb-calculated-cap-10.xml | 0 .../src/test/resources/r4/adi-cs.json | 0 .../src/test/resources/r4/adi-ptbundle.json | 0 .../src/test/resources/r4/adi-vs.json | 0 .../src/test/resources/r4/adi-vs2.json | 0 .../src/test/resources/r4/batch-error.xml | 0 .../r4/bl/bb-obs-code-in-valueset.json | 0 .../r4/bl/bb-obs-code-not-in-valueset.json | 0 .../r4/bl/bb-obs-value-is-not-quantity.json | 0 .../r4/bl/bb-obs-value-is-not-quantity2.json | 0 .../src/test/resources/r4/bl/bb-sd.json | 0 .../src/test/resources/r4/bl/bb-vs.json | 0 .../src/test/resources/r4}/bug-410-bundle.xml | 5 +- .../src/test/resources/r4/bug147-bundle.json | 0 .../src/test/resources/r4/bug801.json | 0 .../test/resources/r4/bug832-korean-text.xml | 0 .../src/test/resources/r4/bundle.xml | 0 ...n-unknown-system-with-required-binding.xml | 0 .../resources/r4/codesystem_complete.json | 0 .../test/resources/r4/collection-bundle.json | 0 .../src/test/resources/r4/conceptmap.json | 0 .../test/resources/r4/createdeletebundle.json | 0 .../resources/r4/custom_resource_patient.json | 0 .../test/resources/r4/document-bundle.json | 0 .../test/resources/r4/document-father.json | 0 .../test/resources/r4/documentmanifest.json | 0 .../test/resources/r4/documentreference.json | 0 .../src/test/resources/r4/eob-bundle.json | 0 .../resources/r4/fragment/codesystem.json | 0 .../r4/fragment/structuredefinition.json | 0 .../test/resources/r4/fragment/valueset.json | 0 .../iar/CodeSystem-iar-citizenship-status.xml | 0 .../iar/ValueSet-iar-citizenship-status.xml | 0 .../resources/r4/identical-tags-batch.json | 0 .../src/test/resources/r4/imagingstudy.json | 0 .../src/test/resources/r4/impact-sp.json | 0 .../test/resources/r4/large-transaction.json | 0 .../src/test/resources/r4/load_bundle.json | 0 .../src/test/resources/r4/oruBundle.json | 0 .../src/test/resources/r4/post1.xml | 0 .../src/test/resources/r4/post2.xml | 0 .../resources/r4/preexisting-patient.json | 0 .../r4/profile-differential-patient-r4.json | 0 .../r4/profile-vitalsigns-all-loinc.json | 0 ...reate-structuredefinition-vital-signs.json | 0 .../src/test/resources/r4/r4_transaction2.xml | 0 .../test/resources/r4/sd-david-dhtest7.json | 0 .../tls_communication_bug_communication.json | 0 .../r4/transaction-no-contained-2.json | 0 .../r4/transaction-no-contained.json | 0 .../transaction-perf-bundle-smallchanges.json | 0 .../resources/r4/transaction-perf-bundle.json | 0 .../r4/uscore/CodeSystem-cdcrec.json | 0 .../r4/uscore/CodeSystem-dummy-loinc.json | 0 .../StructureDefinition-us-core-birthsex.json | 0 ...StructureDefinition-us-core-ethnicity.json | 0 ...ureDefinition-us-core-observation-lab.json | 0 .../StructureDefinition-us-core-patient.json | 0 ...tureDefinition-us-core-pulse-oximetry.json | 0 .../StructureDefinition-us-core-race.json | 0 .../r4/uscore/ValueSet-birthsex.json | 0 .../uscore/ValueSet-detailed-ethnicity.json | 0 .../r4/uscore/ValueSet-detailed-race.json | 0 .../ValueSet-omb-ethnicity-category.json | 0 .../r4/uscore/ValueSet-omb-race-category.json | 0 .../uscore/ValueSet-us-core-usps-state.json | 0 .../r4/uscore/observation-pulseox.json | 0 .../r4/uscore/observation-resource-good.json | 0 .../r4/uscore/patient-resource-badcode.json | 0 .../r4/uscore/patient-resource-good.json | 0 .../src/test/resources/term-delta-json.json | 0 .../transaction-with-full-request-url.json | 0 ...tion-with-preceding-slash-request-url.json | 0 hapi-fhir-jpaserver-test-r5/pom.xml | 113 +++++++++ .../ca/uhn/fhir/jpa/dao/r5/BaseJpaR5Test.java | 0 .../r5/FhirResourceDaoR5CodeSystemTest.java | 0 .../r5/FhirResourceDaoR5SearchNoFtTest.java | 0 ...ResourceDaoR5ValueSetMultiVersionTest.java | 0 .../dao/r5/FhirResourceDaoR5ValueSetTest.java | 0 .../dao/r5/SearchParamExtractorR5Test.java | 22 -- .../r5/StorageInterceptorEventsR5Test.java | 2 - .../r5/AuthorizationInterceptorJpaR5Test.java | 2 - .../r5/BaseResourceProviderR5Test.java | 3 +- ...ceProviderR5CodeSystemDesignationTest.java | 14 +- .../r5/ResourceProviderR5CodeSystemTest.java | 10 +- ...urceProviderR5CodeSystemVersionedTest.java | 8 +- .../r5/ResourceProviderR5ConceptMapTest.java | 0 .../provider/r5/ResourceProviderR5Test.java | 42 ++-- .../r5/ResourceProviderR5ValueSetTest.java | 7 +- ...sourceProviderR5ValueSetVersionedTest.java | 10 +- .../fhir/jpa/provider/r5/ServerR5Test.java | 0 .../subscription/BaseSubscriptionsR5Test.java | 0 .../resthook/RestHookTestR5Test.java | 236 +++++++++--------- .../ca/uhn/fhir/jpa/dao/DaoTestUtils.java | 34 +++ ...PartitionInterceptorReadAllPartitions.java | 0 ...nterceptorReadPartitionsBasedOnScopes.java | 3 - .../uhn/fhir/jpa/packages/FakeNpmServlet.java | 46 ++++ .../jpa/provider/GraphQLProviderTestUtil.java | 6 + .../jpa/subscription/CountingInterceptor.java | 0 .../jpa/subscription/NotificationServlet.java | 0 .../subscription/SocketImplementation.java | 13 +- .../ca/uhn/fhir/jpa/term/TermTestUtil.java | 159 ++++++++++++ .../fhir/jpa/term/ZipCollectionBuilder.java | 0 .../ca/uhn/fhir/jpa/test/BaseJpaTest.java | 12 - .../jpa/util/CoordCalculatorTestUtil.java | 19 ++ .../ForceSynchronousSearchInterceptor.java | 0 .../{test => main}/resources/basic-stu3.xml | 0 .../{test => main}/resources/bryn-bundle.json | 0 .../{test => main}/resources/bug454_utf8.json | 0 .../resources/bug872-ext-with-hl7-url.json | 0 .../resources/bug_516_invalid_expansion.json | 0 .../{test => main}/resources/cdr-bundle.json | 0 .../resources/custom_term/codesystem.json | 0 .../resources/custom_term/concepts.csv | 0 .../resources/custom_term/hierarchy.csv | 0 .../resources/custom_term/properties.csv | 0 .../resources/david-bundle-error.json | 0 .../resources/david_big_bundle.json | 0 .../resources/documentmanifest.json | 0 .../resources/documentreference.json | 0 .../{test => main}/resources/dstu3-post1.xml | 0 .../{test => main}/resources/dstu3-post2.xml | 0 .../resources/dstu3_transaction.xml | 0 ...ional-case-3-cs-with-designations-lang.xml | 0 ...xtensional-case-3-cs-with-designations.xml | 0 .../resources/extensional-case-3-cs.xml | 0 .../extensional-case-3-vs-with-exclude.xml | 0 .../resources/extensional-case-3-vs.xml | 0 .../resources/extensional-case-dstu3.xml | 0 .../resources/icd/icd10cm_tabular_2021.xml | 0 .../resources/imagingstudy.json | 0 .../{test => main}/resources/josh-bundle.json | 0 .../loinc-ver/loincupload.properties | 0 .../loincupload_singlepartlink.properties | 0 .../AccessoryFiles/AnswerFile/AnswerList.csv | 0 .../AnswerFile/LoincAnswerListLink.csv | 0 .../ConsumerName/ConsumerName.csv | 0 .../DocumentOntology/DocumentOntology.csv | 0 .../AccessoryFiles/GroupFile/Group.csv | 0 .../GroupFile/GroupLoincTerms.csv | 0 .../AccessoryFiles/GroupFile/ParentGroup.csv | 0 .../ImagingDocuments/ImagingDocumentCodes.csv | 0 .../LinguisticVariants/LinguisticVariants.csv | 0 .../deAT24LinguisticVariant.csv | 0 .../frCA8LinguisticVariant.csv | 0 .../zhCN5LinguisticVariant.csv | 0 ...LoincIeeeMedicalDeviceCodeMappingTable.csv | 0 .../LoincRsnaRadiologyPlaybook.csv | 0 .../LoincUniversalLabOrdersValueSet.csv | 0 .../MultiAxialHierarchy.csv | 0 .../PanelsAndForms/AnswerList.csv | 0 .../AccessoryFiles/PanelsAndForms/Loinc.csv | 0 .../PanelsAndForms/LoincAnswerListLink.csv | 0 .../AccessoryFiles/PartFile/LoincPartLink.csv | 0 .../PartFile/LoincPartLink_Primary.csv | 0 .../PartFile/LoincPartLink_Supplementary.csv | 0 .../AccessoryFiles/PartFile/Part.csv | 0 .../PartFile/PartRelatedCodeMapping.csv | 0 .../SI/Top2000CommonLabResultsSi.csv | 0 .../US/Top2000CommonLabResultsUs.csv | 0 .../v-no-version/LoincTable/Loinc.csv | 0 .../loinc-ver/v-no-version/loinc.xml | 0 .../AccessoryFiles/AnswerFile/AnswerList.csv | 0 .../AnswerFile/LoincAnswerListLink.csv | 0 .../ConsumerName/ConsumerName.csv | 0 .../DocumentOntology/DocumentOntology.csv | 0 .../v267/AccessoryFiles/GroupFile/Group.csv | 0 .../GroupFile/GroupLoincTerms.csv | 0 .../AccessoryFiles/GroupFile/ParentGroup.csv | 0 .../ImagingDocuments/ImagingDocumentCodes.csv | 0 .../LinguisticVariants/LinguisticVariants.csv | 0 .../deAT24LinguisticVariant.csv | 0 .../frCA8LinguisticVariant.csv | 0 .../zhCN5LinguisticVariant.csv | 0 ...LoincIeeeMedicalDeviceCodeMappingTable.csv | 0 .../LoincRsnaRadiologyPlaybook.csv | 0 .../LoincUniversalLabOrdersValueSet.csv | 0 .../MultiAxialHierarchy.csv | 0 .../PanelsAndForms/AnswerList.csv | 0 .../AccessoryFiles/PanelsAndForms/Loinc.csv | 0 .../PanelsAndForms/LoincAnswerListLink.csv | 0 .../AccessoryFiles/PartFile/LoincPartLink.csv | 0 .../PartFile/LoincPartLink_Primary.csv | 0 .../PartFile/LoincPartLink_Supplementary.csv | 0 .../v267/AccessoryFiles/PartFile/Part.csv | 0 .../PartFile/PartRelatedCodeMapping.csv | 0 .../SI/Top2000CommonLabResultsSi.csv | 0 .../US/Top2000CommonLabResultsUs.csv | 0 .../loinc-ver/v267/LoincTable/Loinc.csv | 0 .../resources/loinc-ver/v267/loinc.xml | 0 .../AccessoryFiles/AnswerFile/AnswerList.csv | 0 .../AnswerFile/LoincAnswerListLink.csv | 0 .../ConsumerName/ConsumerName.csv | 0 .../DocumentOntology/DocumentOntology.csv | 0 .../v268/AccessoryFiles/GroupFile/Group.csv | 0 .../GroupFile/GroupLoincTerms.csv | 0 .../AccessoryFiles/GroupFile/ParentGroup.csv | 0 .../ImagingDocuments/ImagingDocumentCodes.csv | 0 .../LinguisticVariants/LinguisticVariants.csv | 0 .../deAT24LinguisticVariant.csv | 0 .../frCA8LinguisticVariant.csv | 0 .../zhCN5LinguisticVariant.csv | 0 ...LoincIeeeMedicalDeviceCodeMappingTable.csv | 0 .../LoincRsnaRadiologyPlaybook.csv | 0 .../LoincUniversalLabOrdersValueSet.csv | 0 .../MultiAxialHierarchy.csv | 0 .../PanelsAndForms/AnswerList.csv | 0 .../AccessoryFiles/PanelsAndForms/Loinc.csv | 0 .../PanelsAndForms/LoincAnswerListLink.csv | 0 .../AccessoryFiles/PartFile/LoincPartLink.csv | 0 .../PartFile/LoincPartLink_Primary.csv | 0 .../PartFile/LoincPartLink_Supplementary.csv | 0 .../v268/AccessoryFiles/PartFile/Part.csv | 0 .../PartFile/PartRelatedCodeMapping.csv | 0 .../SI/Top2000CommonLabResultsSi.csv | 0 .../US/Top2000CommonLabResultsUs.csv | 0 .../loinc-ver/v268/LoincTable/Loinc.csv | 0 .../resources/loinc-ver/v268/loinc.xml | 0 .../AccessoryFiles/AnswerFile/AnswerList.csv | 0 .../AnswerFile/LoincAnswerListLink.csv | 0 .../ConsumerName/ConsumerName.csv | 0 .../DocumentOntology/DocumentOntology.csv | 0 .../v269/AccessoryFiles/GroupFile/Group.csv | 0 .../GroupFile/GroupLoincTerms.csv | 0 .../AccessoryFiles/GroupFile/ParentGroup.csv | 0 .../ImagingDocuments/ImagingDocumentCodes.csv | 0 .../LinguisticVariants/LinguisticVariants.csv | 0 .../deAT24LinguisticVariant.csv | 0 .../frCA8LinguisticVariant.csv | 0 .../zhCN5LinguisticVariant.csv | 0 ...LoincIeeeMedicalDeviceCodeMappingTable.csv | 0 .../LoincRsnaRadiologyPlaybook.csv | 0 .../LoincUniversalLabOrdersValueSet.csv | 0 .../MultiAxialHierarchy.csv | 0 .../PanelsAndForms/AnswerList.csv | 0 .../AccessoryFiles/PanelsAndForms/Loinc.csv | 0 .../PanelsAndForms/LoincAnswerListLink.csv | 0 .../AccessoryFiles/PartFile/LoincPartLink.csv | 0 .../PartFile/LoincPartLink_Primary.csv | 0 .../PartFile/LoincPartLink_Supplementary.csv | 0 .../v269/AccessoryFiles/PartFile/Part.csv | 0 .../PartFile/PartRelatedCodeMapping.csv | 0 .../SI/Top2000CommonLabResultsSi.csv | 0 .../US/Top2000CommonLabResultsUs.csv | 0 .../loinc-ver/v269/LoincTable/Loinc.csv | 0 .../resources/loinc-ver/v269/loinc.xml | 0 .../AccessoryFiles/AnswerFile/AnswerList.csv | 0 .../AnswerFile/LoincAnswerListLink.csv | 0 .../ConsumerName/ConsumerName.csv | 0 .../DocumentOntology/DocumentOntology.csv | 0 .../loinc/AccessoryFiles/GroupFile/Group.csv | 0 .../GroupFile/GroupLoincTerms.csv | 0 .../AccessoryFiles/GroupFile/ParentGroup.csv | 0 .../ImagingDocuments/ImagingDocumentCodes.csv | 0 .../LinguisticVariants/LinguisticVariants.csv | 0 .../deAT24LinguisticVariant.csv | 0 .../frCA8LinguisticVariant.csv | 0 .../zhCN5LinguisticVariant.csv | 0 ...LoincIeeeMedicalDeviceCodeMappingTable.csv | 0 .../LoincRsnaRadiologyPlaybook.csv | 0 .../LoincUniversalLabOrdersValueSet.csv | 0 .../MultiAxialHierarchy.csv | 0 .../PanelsAndForms/AnswerList.csv | 0 .../AccessoryFiles/PanelsAndForms/Loinc.csv | 0 .../PanelsAndForms/LoincAnswerListLink.csv | 0 .../AccessoryFiles/PartFile/LoincPartLink.csv | 0 .../PartFile/LoincPartLink_Primary.csv | 0 .../PartFile/LoincPartLink_Supplementary.csv | 0 .../loinc/AccessoryFiles/PartFile/Part.csv | 0 .../PartFile/PartRelatedCodeMapping.csv | 0 .../SI/Top2000CommonLabResultsSi.csv | 0 .../US/Top2000CommonLabResultsUs.csv | 0 .../resources/loinc/LoincTable/Loinc.csv | 0 .../{test => main}/resources/loinc/loinc.xml | 0 .../resources/loinc/loincupload.properties | 0 .../loincupload_singlepartlink.properties | 0 .../loinc/v267_loincupload.properties | 0 .../v268_curr_false_loincupload.properties | 0 .../loinc/v268_loincupload.properties | 0 .../resources/packages/UK.Core.r4-1.1.0.tgz | Bin .../resources/packages/basisprofil.de.tar.gz | Bin .../resources/packages/erroneous-ig.tar.gz | Bin .../packages/hl7.fhir.uv.shorthand-0.11.0.tgz | Bin .../packages/hl7.fhir.uv.shorthand-0.11.1.tgz | Bin .../packages/hl7.fhir.uv.shorthand-0.12.0.tgz | Bin .../packages/hl7.fhir.uv.shorthand-0.13.0.tgz | Bin ...ctiz.fhir.nl.stu3.questionnaires-1.0.2.tgz | Bin .../packages/package-davinci-cdex-0.2.0.tgz | Bin .../packages/test-auto-create-placeholder.tgz | Bin .../resources/packages/test-draft-sample.tgz | Bin .../packages/test-exchange-sample-2.tgz | Bin .../packages/test-exchange-sample.tgz | Bin .../test-logical-structuredefinition.tgz | Bin .../test-missing-identifier-package.tgz | Bin .../packages/test-organizations-package.tgz | Bin .../resources/r4/extensional-case-r4.xml | 0 .../resources/r4/extensional-case.xml | 0 .../resources/sample-document.xml | 0 .../sct/sct2_Concept_Full-en_INT_20160131.txt | 0 .../sct/sct2_Concept_Full_INT_20160131.txt | 0 .../sct2_Description_Full-en_INT_20160131.txt | 0 .../sct/sct2_Identifier_Full_INT_20160131.txt | 0 .../sct2_Relationship_Full_INT_20160131.txt | 0 ...2_StatedRelationship_Full_INT_20160131.txt | 0 ...t2_TextDefinition_Full-en_INT_20160131.txt | 0 .../resources/simone-conditional-url.xml | 0 .../resources/simone_bundle.xml | 0 .../resources/simone_bundle2.xml | 0 .../resources/simone_bundle3.xml | 0 .../resources/transaction-bundle.xml | 0 .../transaction_link_patient_eve.xml | 0 .../transaction_link_patient_eve_temp.xml | 0 .../src/{test => main}/resources/update.xml | 0 .../resources/valueset-dstu2.json | 0 .../jpa/term/job/DynamicJobFlowSandbox.java | 2 +- .../fhir/jpa/util/CoordCalculatorTest.java | 48 ++-- .../fhir/jpa/z/ZContextCloserDstu2Test.java | 20 -- pom.xml | 4 + test-job-template.yml | 1 + 709 files changed, 1574 insertions(+), 1120 deletions(-) create mode 100644 hapi-fhir-jpaserver-test-dstu2/pom.xml rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2SystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java (96%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java (96%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchNoFtTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2UpdateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2ValidateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoValueSetDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/BaseResourceProviderDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/QuestionnaireResourceProviderDstu2.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2ValueSetTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/SubscriptionsDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderTransactionSearchDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/search/BaseSearchSvc.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/search/SearchCoordinatorSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/search/SynchronousSearchSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java (83%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java (95%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java (95%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu2Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/java/ca/uhn/fhir/validator/ValidatorAcrossVersionsTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/allergyintolerance-sd-david.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/binu_testpatient_resource.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/binu_testpatient_structuredefinition_dstu2.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/bug147-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/bug638.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/document-father.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/dstu2/Conformance-server.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/dstu2/createdeletebundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/extensional-case-2.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/issue534/bw_profile_snapshot.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/issue534/example_profile.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/issue534/fiphr-vs-bodysite.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu2}/src/test/resources/issue534/fiphr-vs-observationmethod.xml (100%) create mode 100644 hapi-fhir-jpaserver-test-dstu3/pom.xml rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/BaseJpaDstu3SystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirDaoConcurrencyDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoCustomTypeDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDocumentDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3CodeSystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ConceptMapTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ContainedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ExternalReferenceTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3PhoneticSearchNoFtTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ReferentialIntegrityTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchCustomSearchParamTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java (84%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchNoFtTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchSqlTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3StructureDefinitionTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3TerminologyTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValidateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetMultiVersionTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoTransactionDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java (67%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/packages/NpmDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CompositionDocumentDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java (92%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java (87%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/PatientEverythingDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/QuestionnaireResourceProviderDstu3.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderCustomSearchParamDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDeleteSqlDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java (93%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemVersionedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ConceptMapTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java (78%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetVersionedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderExpungeDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderR3CodeSystemDesignationTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java (92%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ServerDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SubscriptionsDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SystemProviderTransactionSearchDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/search/PagingMultinodeProviderDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/searchparam/MatchUrlServiceTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java (87%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSenderImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java (96%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/SubscriptionTriggeringDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java (95%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java (94%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/java/ca/uhn/fhir/validator/AttachmentUtilTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/batch-error.xml (100%) rename {hapi-fhir-jpaserver-test-utilities/src/test/resources/r4 => hapi-fhir-jpaserver-test-dstu3/src/test/resources}/bug-410-bundle.xml (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/bug1044-bundle.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/bug147-bundle-dstu3.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/bundle-dstu3.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/document-bundle-dstu3.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/document-father-dstu3.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/Reilly_Libby_73.json.gz (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/duplicate-conditional-create.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/fmc01-cs-yesnounk.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/fmc03-cs-binderrecommend.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/fmc03-questionnaire.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/fmc03-questionnaireresponse.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/fmc03-vs-binderrecommend.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/fmc03-vs-fmcyesno.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/iar/CodeSystem-iar-citizenship-status.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/iar/ValueSet-iar-citizenship-status.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/nl/LandISOCodelijst-2.16.840.1.113883.2.4.3.11.60.40.2.20.5.2--20171231000000.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/no-store-header/episodeofcare-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/no-store-header/location-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/no-store-header/organization-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/no-store-header/patient-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/no-store-header/practitioner-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/profile-differential-patient-dstu3.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3/slow_bundle.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3_codesystem_complete.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3_custom_resource_patient.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/dstu3_transaction2.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/mihin-resource-dstu3.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/oruBundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.10.tgz (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.9.tgz (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/questionnaire_dstu3.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-dstu3}/src/test/resources/sd-david-dhtest7.json (100%) create mode 100644 hapi-fhir-jpaserver-test-r4/pom.xml rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/batch2/JobInstanceRepositoryTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/batch2/JpaJobPersistenceImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/binstore/DatabaseBlobBinaryStorageSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java (95%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/binstore/NullBinaryStorageSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/bulk/BulkDataExportProviderTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/BulkImportR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/ConsumeFilesStepR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirDaoTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java (94%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/TolerantJsonParserR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/TransactionProcessorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/expunge/DeleteExpungeDaoTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ResourceTableFKProviderTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseComboParamsR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseJpaR4SystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/BasePartitioningR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/ChainingR4SearchTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCreatePlaceholdersR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCustomTypeR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoDocumentR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CodeSystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboNonUniqueParamTest.java (100%) rename hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamTest.java => hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamIT.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConceptMapTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConcurrentWriteTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ContainedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4DeleteTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4FilterTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4HistoryRewriteTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InlineResourceModeTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4MetaTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4QueryCountTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ReferentialIntegrityTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchCustomSearchParamTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java (76%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchFtTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchIncludeTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchMissingTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoFtTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoHashesTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchOptimizedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchPageExpiryTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchSqlTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchWithHSearchDisabledTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SelectiveUpdateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SortTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StandardQueriesNoFTTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StructureDefinitionTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TagsTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java (87%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTagSnapshotTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValidateTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4VersionedReferenceTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchListTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchParameterR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSearchDaoR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/JpaHistoryR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSqlR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParamExtractorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchWithInterceptorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/SyntheaPerfTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/TestContextLoads.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionHookTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/delete/DeleteConflictServiceR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/delete/job/DeleteExpungeJobTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexJobTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexTestHelper.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java (95%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/CascadingDeleteInterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/ForceOffsetSearchModeInterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/PatientIdPartitionInterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/ResponseTerminologyTranslationInterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java (93%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/ValidationMessageSuppressingInterceptorTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java (91%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/packages/NpmSearchR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java (88%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/partition/RequestPartitionHelperSvcTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchApplyR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchDiffR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java (92%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/TerminologyUploaderProviderTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorMultitenantJpaR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/BaseMultitenantResourceProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryAccessProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/CompositionDocumentR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ConsentInterceptorResourceProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java (92%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java (54%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ExpungeR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/HookInterceptorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/MemberMatcherR4HelperTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java (90%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantServerR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/NicknameSearchR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/OpenApiInterceptorJpaTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatchProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientEverythingR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientMemberMatchOperationR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/RemoteTerminologyServiceResourceProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderConcurrencyR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderCustomSearchParamR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderExpungeR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderHasParamR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInterceptorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInvalidDataR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderOnlySomeResourcesProvidedR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderQuestionnaireResponseR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4BundleTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CacheTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemDesignationTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ConceptMapTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java (77%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4RemoteTerminologyTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4SearchContainedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4StructureDefinitionTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetHSearchDisabledTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSearchModifierR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerCapabilityStatementProviderJpaR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/StaleSearchDeletingSvcR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/SubscriptionsR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/provider/r4/TerminologyUploaderProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/reindex/ResourceReindexSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao => hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa}/search/ExtendedHSearchResourceProjectionTest.java (92%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/search/r4/PagingMultinodeProviderR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/stresstest/GiantTransactionPerfTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/stresstest/README.txt (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestParserTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java (92%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithEventDefinitionR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java (95%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/BaseLoaderTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/ITermReadSvcTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TermVersionAdapterSvcR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java (93%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java (79%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java (96%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/ValueSetHSearchExpansionR4LuceneIT.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/hsearch/ReindexTerminologyHSearchR4Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java (97%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/term/loinc/BaseLoincHandlerTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/util/ValueSetTestUtil.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/dstu3-person.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/duplicate-conditional-create.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/imgthla/bogus.txt (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/imgthla/hla.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/imgthla/hla_nom.txt (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/largecodesystem/ValueSetV.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/largecodesystem/ValueSetV1.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/largecodesystem/concepts.csv (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/largecodesystem/hierarchy.csv (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/largecodesystem/observation-matching.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/largecodesystem/observation-non-matching.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/loinc-reindex/Loinc_small_v68.zip (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/loinc-reindex/v268_loincupload.properties (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/npe-causing-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/packages/de.basisprofil.r4-1.2.0.tgz (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/CodeSystem-iar-chymh-cb-calculated-cap-10.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/ConceptMap-icd-sct.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/StructureDefinition-kfdrc-patient-no-phi.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/StructureDefinition-kfdrc-patient.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/ValueSet-iar-chymh-cb-calculated-cap-10.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/adi-cs.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/adi-ptbundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/adi-vs.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/adi-vs2.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/batch-error.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bl/bb-obs-code-in-valueset.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bl/bb-obs-code-not-in-valueset.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bl/bb-obs-value-is-not-quantity.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bl/bb-obs-value-is-not-quantity2.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bl/bb-sd.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bl/bb-vs.json (100%) rename {hapi-fhir-jpaserver-test-utilities/src/test/resources => hapi-fhir-jpaserver-test-r4/src/test/resources/r4}/bug-410-bundle.xml (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bug147-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bug801.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bug832-korean-text.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/bundle.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/code-in-unknown-system-with-required-binding.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/codesystem_complete.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/collection-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/conceptmap.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/createdeletebundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/custom_resource_patient.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/document-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/document-father.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/documentmanifest.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/documentreference.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/eob-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/fragment/codesystem.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/fragment/structuredefinition.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/fragment/valueset.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/iar/CodeSystem-iar-citizenship-status.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/iar/ValueSet-iar-citizenship-status.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/identical-tags-batch.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/imagingstudy.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/impact-sp.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/large-transaction.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/load_bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/oruBundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/post1.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/post2.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/preexisting-patient.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/profile-differential-patient-r4.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/profile-vitalsigns-all-loinc.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/r4-create-structuredefinition-vital-signs.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/r4_transaction2.xml (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/sd-david-dhtest7.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/tls_communication_bug_communication.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/transaction-no-contained-2.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/transaction-no-contained.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/transaction-perf-bundle-smallchanges.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/transaction-perf-bundle.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/CodeSystem-cdcrec.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/CodeSystem-dummy-loinc.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/StructureDefinition-us-core-birthsex.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/StructureDefinition-us-core-ethnicity.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/StructureDefinition-us-core-observation-lab.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/StructureDefinition-us-core-patient.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/StructureDefinition-us-core-pulse-oximetry.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/StructureDefinition-us-core-race.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/ValueSet-birthsex.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/ValueSet-detailed-ethnicity.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/ValueSet-detailed-race.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/ValueSet-omb-ethnicity-category.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/ValueSet-omb-race-category.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/ValueSet-us-core-usps-state.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/observation-pulseox.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/observation-resource-good.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/patient-resource-badcode.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/r4/uscore/patient-resource-good.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/term-delta-json.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/transaction-bundles/transaction-with-full-request-url.json (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r4}/src/test/resources/transaction-bundles/transaction-with-preceding-slash-request-url.json (100%) create mode 100644 hapi-fhir-jpaserver-test-r5/pom.xml rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/BaseJpaR5Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5CodeSystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5SearchNoFtTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetMultiVersionTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java (64%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java (98%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ConceptMapTest.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java (99%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/provider/r5/ServerR5Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR5Test.java (100%) rename {hapi-fhir-jpaserver-test-utilities => hapi-fhir-jpaserver-test-r5}/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java (75%) create mode 100644 hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/dao/DaoTestUtils.java rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadAllPartitions.java (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java (91%) create mode 100644 hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/packages/FakeNpmServlet.java create mode 100644 hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/provider/GraphQLProviderTestUtil.java rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/subscription/CountingInterceptor.java (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/subscription/NotificationServlet.java (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java (91%) create mode 100644 hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/term/TermTestUtil.java rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/term/ZipCollectionBuilder.java (100%) create mode 100644 hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/util/CoordCalculatorTestUtil.java rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/java/ca/uhn/fhir/jpa/util/ForceSynchronousSearchInterceptor.java (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/basic-stu3.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/bryn-bundle.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/bug454_utf8.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/bug872-ext-with-hl7-url.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/bug_516_invalid_expansion.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/cdr-bundle.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/custom_term/codesystem.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/custom_term/concepts.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/custom_term/hierarchy.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/custom_term/properties.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/david-bundle-error.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/david_big_bundle.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/documentmanifest.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/documentreference.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/dstu3-post1.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/dstu3-post2.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/dstu3_transaction.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/extensional-case-3-cs-with-designations-lang.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/extensional-case-3-cs-with-designations.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/extensional-case-3-cs.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/extensional-case-3-vs-with-exclude.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/extensional-case-3-vs.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/extensional-case-dstu3.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/icd/icd10cm_tabular_2021.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/imagingstudy.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/josh-bundle.json (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/loincupload.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/loincupload_singlepartlink.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/ConsumerName/ConsumerName.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/DocumentOntology/DocumentOntology.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/Group.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/GroupLoincTerms.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/ParentGroup.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Primary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/Part.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/LoincTable/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v-no-version/loinc.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/ConsumerName/ConsumerName.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/DocumentOntology/DocumentOntology.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/GroupFile/Group.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/GroupFile/GroupLoincTerms.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/GroupFile/ParentGroup.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Primary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PartFile/Part.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/LoincTable/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v267/loinc.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/ConsumerName/ConsumerName.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/DocumentOntology/DocumentOntology.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/GroupFile/Group.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/GroupFile/GroupLoincTerms.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/GroupFile/ParentGroup.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Primary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PartFile/Part.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/LoincTable/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v268/loinc.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/ConsumerName/ConsumerName.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/DocumentOntology/DocumentOntology.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/GroupFile/Group.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/GroupFile/GroupLoincTerms.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/GroupFile/ParentGroup.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Primary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PartFile/Part.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/LoincTable/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc-ver/v269/loinc.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/AnswerFile/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/ConsumerName/ConsumerName.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/DocumentOntology/DocumentOntology.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/GroupFile/Group.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/GroupFile/GroupLoincTerms.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/GroupFile/ParentGroup.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PanelsAndForms/AnswerList.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PanelsAndForms/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PartFile/LoincPartLink.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Primary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PartFile/Part.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/LoincTable/Loinc.csv (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/loinc.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/loincupload.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/loincupload_singlepartlink.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/v267_loincupload.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/v268_curr_false_loincupload.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/loinc/v268_loincupload.properties (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/UK.Core.r4-1.1.0.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/basisprofil.de.tar.gz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/erroneous-ig.tar.gz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/hl7.fhir.uv.shorthand-0.11.0.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/hl7.fhir.uv.shorthand-0.11.1.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/hl7.fhir.uv.shorthand-0.12.0.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/hl7.fhir.uv.shorthand-0.13.0.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/nictiz.fhir.nl.stu3.questionnaires-1.0.2.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/package-davinci-cdex-0.2.0.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-auto-create-placeholder.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-draft-sample.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-exchange-sample-2.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-exchange-sample.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-logical-structuredefinition.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-missing-identifier-package.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/packages/test-organizations-package.tgz (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/r4/extensional-case-r4.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/r4/extensional-case.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sample-document.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_Concept_Full-en_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_Concept_Full_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_Description_Full-en_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_Identifier_Full_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_Relationship_Full_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_StatedRelationship_Full_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/sct/sct2_TextDefinition_Full-en_INT_20160131.txt (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/simone-conditional-url.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/simone_bundle.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/simone_bundle2.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/simone_bundle3.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/transaction-bundle.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/transaction_link_patient_eve.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/transaction_link_patient_eve_temp.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/update.xml (100%) rename hapi-fhir-jpaserver-test-utilities/src/{test => main}/resources/valueset-dstu2.json (100%) delete mode 100644 hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ZContextCloserDstu2Test.java diff --git a/azure-pipelines.yml b/azure-pipelines.yml index f98108103af..c89336d3689 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -18,6 +18,14 @@ stages: - template: test-job-template.yml parameters: modules: + - name: hapi_fhir_jpaserver_test_dstu2 + module: hapi-fhir-jpaserver-test-dstu2 + - name: hapi_fhir_jpaserver_test_dstu3 + module: hapi-fhir-jpaserver-test-dstu3 + - name: hapi_fhir_jpaserver_test_r4 + module: hapi-fhir-jpaserver-test-r4 + - name: hapi_fhir_jpaserver_test_r5 + module: hapi-fhir-jpaserver-test-r5 - name: hapi_fhir_jpaserver_test_utilities module: hapi-fhir-jpaserver-test-utilities - name: hapi_fhir_structures_r4 @@ -52,9 +60,9 @@ stages: module: hapi-fhir-jaxrsserver-base - name: hapi_fhir_jpa module: hapi-fhir-jpa -# Put to top, but kept in order here -# - name: hapi_fhir_jpaserver_base -# module: hapi-fhir-jpaserver-base + # Put to top, but kept in order here + # - name: hapi_fhir_jpaserver_base + # module: hapi-fhir-jpaserver-base - name: hapi_fhir_jpaserver_cql module: hapi-fhir-jpaserver-cql - name: hapi_fhir_jpaserver_elastic_test_utilities @@ -67,9 +75,9 @@ stages: module: hapi-fhir-jpaserver-searchparam - name: hapi_fhir_jpaserver_subscription module: hapi-fhir-jpaserver-subscription -# Put to top, but kept in order here -# - name: hapi_fhir_jpaserver_test_utilities -# module: hapi-fhir-jpaserver-test-utilities + # Put to top, but kept in order here + # - name: hapi_fhir_jpaserver_test_utilities + # module: hapi-fhir-jpaserver-test-utilities - name: hapi_fhir_jpaserver_uhnfhirtest module: hapi-fhir-jpaserver-uhnfhirtest - name: hapi_fhir_server @@ -100,9 +108,9 @@ stages: module: hapi-fhir-structures-dstu3 - name: hapi_fhir_structures_hl7org_dstu2 module: hapi-fhir-structures-hl7org-dstu2 -# Put to top, but kept in order here -# - name: hapi_fhir_structures_r4 -# module: hapi-fhir-structures-r4 + # Put to top, but kept in order here + # - name: hapi_fhir_structures_r4 + # module: hapi-fhir-structures-r4 - name: hapi_fhir_structures_r5 module: hapi-fhir-structures-r5 - name: hapi_fhir_test_utilities diff --git a/hapi-fhir-jacoco/pom.xml b/hapi-fhir-jacoco/pom.xml index ddf3a3ad863..471a128cf83 100644 --- a/hapi-fhir-jacoco/pom.xml +++ b/hapi-fhir-jacoco/pom.xml @@ -96,6 +96,27 @@ hapi-fhir-jpaserver-test-utilities ${project.version} + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-dstu2 + ${project.version} + + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-dstu3 + ${project.version} + + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-r4 + ${project.version} + + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-r5 + ${project.version} + + + 1 + false + alphabetical + + **/*IT.java + + false + + + + + integration-test + verify + + + + + + org.junit.jupiter + junit-jupiter-engine + ${junit_version} + + + + + org.apache.maven.plugins + maven-surefire-plugin + + alphabetical + @{argLine} ${surefire_jvm_args} + 0.6C + *StressTest* + ${skipFailsafe} + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + true + + + + + + + + NOPARALLEL + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + + **/stresstest/* + + + + + + + + CI + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + alphabetical + + + + + + + + diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java index fd123083046..94a815b68fe 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/config/min/ResourceMinimizerMojo.java @@ -17,7 +17,13 @@ import org.apache.commons.lang3.StringUtils; import org.hl7.fhir.instance.model.api.IBaseBundle; import org.hl7.fhir.instance.model.api.IBaseResource; -import java.io.*; +import java.io.BufferedWriter; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.OutputStreamWriter; +import java.io.Writer; import java.net.URL; import java.util.Collection; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2SystemTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2SystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2SystemTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2SystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java similarity index 96% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java index 923db55bad4..dae619ffd1a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/BaseJpaDstu2Test.java @@ -9,8 +9,6 @@ import ca.uhn.fhir.jpa.api.dao.IFhirResourceDaoValueSet; import ca.uhn.fhir.jpa.api.dao.IFhirSystemDao; import ca.uhn.fhir.jpa.api.svc.ISearchCoordinatorSvc; import ca.uhn.fhir.jpa.bulk.export.api.IBulkDataExportJobSchedulingHelper; -import ca.uhn.fhir.jpa.test.config.TestDstu2Config; -import ca.uhn.fhir.jpa.test.BaseJpaTest; import ca.uhn.fhir.jpa.dao.IFulltextSearchSvc; import ca.uhn.fhir.jpa.dao.data.IResourceIndexedSearchParamStringDao; import ca.uhn.fhir.jpa.dao.data.IResourceIndexedSearchParamTokenDao; @@ -23,6 +21,8 @@ import ca.uhn.fhir.jpa.search.reindex.IResourceReindexingSvc; import ca.uhn.fhir.jpa.searchparam.registry.ISearchParamRegistryController; import ca.uhn.fhir.jpa.sp.ISearchParamPresenceSvc; import ca.uhn.fhir.jpa.subscription.match.registry.SubscriptionLoader; +import ca.uhn.fhir.jpa.test.BaseJpaTest; +import ca.uhn.fhir.jpa.test.config.TestDstu2Config; import ca.uhn.fhir.jpa.util.ResourceCountCache; import ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt; import ca.uhn.fhir.model.dstu2.composite.CodingDt; @@ -58,6 +58,7 @@ import ca.uhn.fhir.model.dstu2.resource.ValueSet; import ca.uhn.fhir.rest.server.provider.ResourceProviderFactory; import ca.uhn.fhir.rest.server.util.ISearchParamRegistry; import org.hl7.fhir.common.hapi.validation.support.ValidationSupportChain; +import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.extension.ExtendWith; @@ -72,8 +73,8 @@ import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.support.TransactionTemplate; import javax.persistence.EntityManager; - -import static org.junit.jupiter.api.Assertions.fail; +import java.util.ArrayList; +import java.util.List; @ExtendWith(SpringExtension.class) @ContextConfiguration(classes = {TestDstu2Config.class}) @@ -262,5 +263,11 @@ public abstract class BaseJpaDstu2Test extends BaseJpaTest { myJpaValidationSupportChain.invalidateCaches(); } - + protected List toUnqualifiedVersionlessIds(Bundle theFound) { + List retVal = new ArrayList<>(); + for (Bundle.Entry next : theFound.getEntry()) { + retVal.add(next.getResource().getId().toUnqualifiedVersionless()); + } + return retVal; + } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java index 0b352fd5290..4559274fd7d 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchCustomSearchParamTest.java @@ -37,7 +37,6 @@ import ca.uhn.fhir.rest.param.TokenParam; import ca.uhn.fhir.rest.server.exceptions.InternalErrorException; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; -import ca.uhn.fhir.rest.server.servlet.ServletRequestDetails; import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java similarity index 96% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java index eea01b9791d..e0f0a65e931 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchFtTest.java @@ -1,27 +1,31 @@ package ca.uhn.fhir.jpa.dao.dstu2; -import static org.hamcrest.MatcherAssert.assertThat; -import static org.hamcrest.Matchers.*; -import static org.junit.jupiter.api.Assertions.*; -import static org.mockito.Mockito.mock; - -import java.util.List; - -import javax.servlet.http.HttpServletRequest; - import ca.uhn.fhir.jpa.dao.BaseHapiFhirResourceDao; +import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.model.dstu2.resource.Device; +import ca.uhn.fhir.model.dstu2.resource.Observation; +import ca.uhn.fhir.model.dstu2.resource.Patient; +import ca.uhn.fhir.model.primitive.StringDt; +import ca.uhn.fhir.rest.api.Constants; +import ca.uhn.fhir.rest.param.StringAndListParam; +import ca.uhn.fhir.rest.param.StringOrListParam; +import ca.uhn.fhir.rest.param.StringParam; import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.springframework.transaction.TransactionStatus; import org.springframework.transaction.support.TransactionCallbackWithoutResult; -import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; -import ca.uhn.fhir.model.dstu2.resource.*; -import ca.uhn.fhir.model.primitive.Base64BinaryDt; -import ca.uhn.fhir.model.primitive.StringDt; -import ca.uhn.fhir.rest.api.Constants; -import ca.uhn.fhir.rest.param.*; +import javax.servlet.http.HttpServletRequest; +import java.util.List; + +import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.contains; +import static org.hamcrest.Matchers.containsInAnyOrder; +import static org.hamcrest.Matchers.empty; +import static org.hamcrest.Matchers.not; +import static org.junit.jupiter.api.Assertions.assertNotEquals; +import static org.mockito.Mockito.mock; public class FhirResourceDaoDstu2SearchFtTest extends BaseJpaDstu2Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchNoFtTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchNoFtTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchNoFtTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2SearchNoFtTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java index 0a207d4360a..4354e713499 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2Test.java @@ -5,8 +5,8 @@ import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.model.HistoryCountModeEnum; import ca.uhn.fhir.jpa.dao.BaseHapiFhirDao; import ca.uhn.fhir.jpa.dao.BaseStorageDao; +import ca.uhn.fhir.jpa.dao.DaoTestUtils; import ca.uhn.fhir.jpa.dao.data.IForcedIdDao; -import ca.uhn.fhir.jpa.dao.dstu3.FhirResourceDaoDstu3Test; import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamString; import ca.uhn.fhir.jpa.model.entity.TagTypeEnum; import ca.uhn.fhir.jpa.searchparam.SearchParamConstants; @@ -609,7 +609,7 @@ public class FhirResourceDaoDstu2Test extends BaseJpaDstu2Test { myOrganizationDao.delete(orgId, mySrd); fail(); } catch (ResourceVersionConflictException e) { - FhirResourceDaoDstu3Test.assertConflictException(e); + DaoTestUtils.assertConflictException(e); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2UpdateTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2UpdateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2UpdateTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2UpdateTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2ValidateTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2ValidateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2ValidateTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoDstu2ValidateTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoValueSetDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoValueSetDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoValueSetDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirResourceDaoValueSetDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java index 59052587adf..3e01fde2b18 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSearchDaoDstu2Test.java @@ -9,8 +9,6 @@ import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import ca.uhn.fhir.rest.param.StringAndListParam; import ca.uhn.fhir.rest.param.StringOrListParam; import ca.uhn.fhir.rest.param.StringParam; -import ca.uhn.fhir.util.TestUtil; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java index 1ef3d34a5ca..5a8aa32a941 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2SearchTest.java @@ -1,10 +1,7 @@ package ca.uhn.fhir.jpa.dao.dstu2; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; -import ca.uhn.fhir.util.TestUtil; - public class FhirSystemDaoDstu2SearchTest extends BaseJpaDstu2SystemTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/dao/dstu2/FhirSystemDaoDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/BaseResourceProviderDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/BaseResourceProviderDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/BaseResourceProviderDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/BaseResourceProviderDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/QuestionnaireResourceProviderDstu2.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/QuestionnaireResourceProviderDstu2.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/QuestionnaireResourceProviderDstu2.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/QuestionnaireResourceProviderDstu2.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2ValueSetTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2ValueSetTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2ValueSetTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderDstu2ValueSetTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java index 8e56373c552..66e1ff78a25 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/ResourceProviderExpungeDstu2Test.java @@ -10,10 +10,8 @@ import ca.uhn.fhir.model.dstu2.valueset.ObservationStatusEnum; import ca.uhn.fhir.rest.server.exceptions.PreconditionFailedException; import ca.uhn.fhir.rest.server.exceptions.ResourceGoneException; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; -import ca.uhn.fhir.util.TestUtil; import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/SubscriptionsDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/SubscriptionsDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/SubscriptionsDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/SubscriptionsDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderTransactionSearchDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderTransactionSearchDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderTransactionSearchDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/provider/SystemProviderTransactionSearchDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/BaseSearchSvc.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/search/BaseSearchSvc.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/BaseSearchSvc.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/search/BaseSearchSvc.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/SearchCoordinatorSvcImplTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/search/SearchCoordinatorSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/SearchCoordinatorSvcImplTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/search/SearchCoordinatorSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/SynchronousSearchSvcImplTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/search/SynchronousSearchSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/SynchronousSearchSvcImplTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/search/SynchronousSearchSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java similarity index 83% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java index 309fb0dc66d..5025defc1d9 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu2Util.java @@ -1,13 +1,19 @@ package ca.uhn.fhir.jpa.subscription; -import org.hl7.fhir.instance.model.api.*; - import ca.uhn.fhir.model.dstu2.composite.CodingDt; import ca.uhn.fhir.model.dstu2.composite.IdentifierDt; -import ca.uhn.fhir.model.dstu2.resource.*; -import ca.uhn.fhir.model.dstu2.valueset.*; +import ca.uhn.fhir.model.dstu2.resource.Observation; +import ca.uhn.fhir.model.dstu2.resource.Patient; +import ca.uhn.fhir.model.dstu2.resource.Subscription; +import ca.uhn.fhir.model.dstu2.valueset.AdministrativeGenderEnum; +import ca.uhn.fhir.model.dstu2.valueset.ObservationStatusEnum; +import ca.uhn.fhir.model.dstu2.valueset.SubscriptionChannelTypeEnum; +import ca.uhn.fhir.model.dstu2.valueset.SubscriptionStatusEnum; import ca.uhn.fhir.rest.api.MethodOutcome; import ca.uhn.fhir.rest.client.api.IGenericClient; +import org.hl7.fhir.instance.model.api.IBaseCoding; +import org.hl7.fhir.instance.model.api.IBaseMetaType; +import org.hl7.fhir.instance.model.api.IBaseResource; public class FhirDstu2Util { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java index 693213104d6..6404bcdd358 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu2Test.java @@ -1,8 +1,8 @@ package ca.uhn.fhir.jpa.subscription.email; import ca.uhn.fhir.jpa.provider.BaseResourceProviderDstu2Test; -import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.jpa.subscription.match.deliver.email.EmailSenderImpl; +import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt; import ca.uhn.fhir.model.dstu2.composite.CodingDt; import ca.uhn.fhir.model.dstu2.resource.Observation; @@ -33,7 +33,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.List; -import static ca.uhn.fhir.jpa.subscription.resthook.RestHookTestDstu3Test.logAllInterceptors; +import static ca.uhn.fhir.jpa.dao.DaoTestUtils.logAllInterceptors; import static org.awaitility.Awaitility.await; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java index 634896120d6..a46165fcb6e 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu2Test.java @@ -40,7 +40,7 @@ import java.util.ArrayList; import java.util.List; import java.util.stream.Collectors; -import static ca.uhn.fhir.jpa.subscription.resthook.RestHookTestDstu3Test.logAllInterceptors; +import static ca.uhn.fhir.jpa.dao.DaoTestUtils.logAllInterceptors; import static org.hamcrest.CoreMatchers.containsString; import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java index 4e47248d1d3..5fd499721b2 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu2Test.java @@ -3,8 +3,8 @@ package ca.uhn.fhir.jpa.subscription.resthook; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.provider.BaseResourceProviderDstu2Test; -import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.jpa.subscription.match.registry.SubscriptionRegistry; +import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.model.dstu2.composite.CodeableConceptDt; import ca.uhn.fhir.model.dstu2.composite.CodingDt; import ca.uhn.fhir.model.dstu2.resource.Observation; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java similarity index 95% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java index 464141c5880..663c0af7397 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu2Test.java @@ -18,6 +18,7 @@ import ca.uhn.fhir.rest.api.MethodOutcome; import org.eclipse.jetty.websocket.api.Session; import org.eclipse.jetty.websocket.client.ClientUpgradeRequest; import org.eclipse.jetty.websocket.client.WebSocketClient; +import org.hamcrest.MatcherAssert; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; @@ -29,7 +30,6 @@ import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; import static org.hamcrest.Matchers.contains; -import static org.hamcrest.MatcherAssert.assertThat; // This is currently disabled as the criteria mechanism was a non-standard experiment @Disabled @@ -121,7 +121,7 @@ public class WebsocketWithCriteriaDstu2Test extends BaseResourceProviderDstu2Tes ourLog.info("WS Messages: {}", mySocketImplementation.getMessages()); waitForSize(2, mySocketImplementation.getMessages()); - assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId, "ping " + mySubscriptionId)); + MatcherAssert.assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId, "ping " + mySubscriptionId)); } @Test @@ -145,6 +145,6 @@ public class WebsocketWithCriteriaDstu2Test extends BaseResourceProviderDstu2Tes waitForSize(2, mySocketImplementation.getMessages()); ourLog.info("WS Messages: {}", mySocketImplementation.getMessages()); - assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId)); + MatcherAssert.assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId)); } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java similarity index 95% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java index 66199375e5b..425e9520d43 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu2Test.java @@ -19,6 +19,7 @@ import ca.uhn.fhir.rest.api.MethodOutcome; import org.eclipse.jetty.websocket.api.Session; import org.eclipse.jetty.websocket.client.ClientUpgradeRequest; import org.eclipse.jetty.websocket.client.WebSocketClient; +import org.hamcrest.MatcherAssert; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; @@ -30,7 +31,6 @@ import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; import static org.hamcrest.Matchers.contains; -import static org.hamcrest.MatcherAssert.assertThat; /** * Adds a FHIR subscription with criteria through the rest interface. Then creates a websocket with the id of the @@ -141,7 +141,7 @@ public class WebsocketWithSubscriptionIdDstu2Test extends BaseResourceProviderDs ourLog.info("WS Messages: {}", mySocketImplementation.getMessages()); waitForSize(2, mySocketImplementation.getMessages()); - assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId, "ping " + mySubscriptionId)); + MatcherAssert.assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId, "ping " + mySubscriptionId)); } @Test @@ -165,6 +165,6 @@ public class WebsocketWithSubscriptionIdDstu2Test extends BaseResourceProviderDs ourLog.info("WS Messages: {}", mySocketImplementation.getMessages()); waitForSize(1, mySocketImplementation.getMessages()); - assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId)); + MatcherAssert.assertThat(mySocketImplementation.getMessages(), contains("bound " + mySubscriptionId)); } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu2Test.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu2Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu2Test.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu2Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java index 21ba230f5b6..ca8b0cdb5f5 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java +++ b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/jpa/z/ResourceMinimizerMojo.java @@ -17,7 +17,13 @@ import org.apache.commons.lang3.StringUtils; import org.hl7.fhir.instance.model.api.IBaseBundle; import org.hl7.fhir.instance.model.api.IBaseResource; -import java.io.*; +import java.io.BufferedWriter; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.OutputStreamWriter; +import java.io.Writer; import java.net.URL; import java.util.Collection; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/validator/ValidatorAcrossVersionsTest.java b/hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/validator/ValidatorAcrossVersionsTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/validator/ValidatorAcrossVersionsTest.java rename to hapi-fhir-jpaserver-test-dstu2/src/test/java/ca/uhn/fhir/validator/ValidatorAcrossVersionsTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/allergyintolerance-sd-david.json b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/allergyintolerance-sd-david.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/allergyintolerance-sd-david.json rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/allergyintolerance-sd-david.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/binu_testpatient_resource.json b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/binu_testpatient_resource.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/binu_testpatient_resource.json rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/binu_testpatient_resource.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/binu_testpatient_structuredefinition_dstu2.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/binu_testpatient_structuredefinition_dstu2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/binu_testpatient_structuredefinition_dstu2.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/binu_testpatient_structuredefinition_dstu2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug147-bundle.json b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/bug147-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug147-bundle.json rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/bug147-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug638.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/bug638.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug638.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/bug638.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/document-father.json b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/document-father.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/document-father.json rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/document-father.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu2/Conformance-server.json b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/dstu2/Conformance-server.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu2/Conformance-server.json rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/dstu2/Conformance-server.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu2/createdeletebundle.json b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/dstu2/createdeletebundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu2/createdeletebundle.json rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/dstu2/createdeletebundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-2.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/extensional-case-2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-2.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/extensional-case-2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/bw_profile_snapshot.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/bw_profile_snapshot.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/bw_profile_snapshot.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/bw_profile_snapshot.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/example_profile.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/example_profile.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/example_profile.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/example_profile.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/fiphr-vs-bodysite.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/fiphr-vs-bodysite.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/fiphr-vs-bodysite.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/fiphr-vs-bodysite.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/fiphr-vs-observationmethod.xml b/hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/fiphr-vs-observationmethod.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/issue534/fiphr-vs-observationmethod.xml rename to hapi-fhir-jpaserver-test-dstu2/src/test/resources/issue534/fiphr-vs-observationmethod.xml diff --git a/hapi-fhir-jpaserver-test-dstu3/pom.xml b/hapi-fhir-jpaserver-test-dstu3/pom.xml new file mode 100644 index 00000000000..48bc6269b0a --- /dev/null +++ b/hapi-fhir-jpaserver-test-dstu3/pom.xml @@ -0,0 +1,113 @@ + + + 4.0.0 + + ca.uhn.hapi.fhir + hapi-deployable-pom + 6.2.0-PRE2-SNAPSHOT + ../hapi-deployable-pom/pom.xml + + + jar + + HAPI FHIR JPA Server Test Dstu3 + hapi-fhir-jpaserver-test-dstu3 + + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-utilities + ${project.version} + test + + + + + + + org.apache.maven.plugins + maven-failsafe-plugin + + + 1 + false + alphabetical + + **/*IT.java + + false + + + + + integration-test + verify + + + + + + org.junit.jupiter + junit-jupiter-engine + ${junit_version} + + + + + org.apache.maven.plugins + maven-surefire-plugin + + alphabetical + @{argLine} ${surefire_jvm_args} + 0.6C + *StressTest* + ${skipFailsafe} + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + true + + + + + + + + NOPARALLEL + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + + **/stresstest/* + + + + + + + + CI + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + alphabetical + + + + + + + + diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/BaseJpaDstu3SystemTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/BaseJpaDstu3SystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/BaseJpaDstu3SystemTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/BaseJpaDstu3SystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java index bc013681ae2..b1a3529c4ae 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/CustomObservationDstu3.java @@ -20,12 +20,11 @@ package ca.uhn.fhir.jpa.dao.dstu3; * #L% */ -import org.hl7.fhir.dstu3.model.Observation; -import org.hl7.fhir.dstu3.model.StringType; - import ca.uhn.fhir.model.api.annotation.Child; import ca.uhn.fhir.model.api.annotation.Extension; import ca.uhn.fhir.model.api.annotation.ResourceDef; +import org.hl7.fhir.dstu3.model.Observation; +import org.hl7.fhir.dstu3.model.StringType; @ResourceDef(name = "Observation", profile = CustomObservationDstu3.PROFILE) public class CustomObservationDstu3 extends Observation { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirDaoConcurrencyDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirDaoConcurrencyDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirDaoConcurrencyDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirDaoConcurrencyDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoCustomTypeDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoCustomTypeDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoCustomTypeDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoCustomTypeDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDocumentDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDocumentDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDocumentDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDocumentDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3CodeSystemTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3CodeSystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3CodeSystemTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3CodeSystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ConceptMapTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ConceptMapTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ConceptMapTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ConceptMapTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ContainedTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ContainedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ContainedTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ContainedTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ExternalReferenceTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ExternalReferenceTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ExternalReferenceTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ExternalReferenceTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3PhoneticSearchNoFtTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3PhoneticSearchNoFtTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3PhoneticSearchNoFtTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3PhoneticSearchNoFtTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ReferentialIntegrityTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ReferentialIntegrityTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ReferentialIntegrityTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ReferentialIntegrityTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchCustomSearchParamTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchCustomSearchParamTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchCustomSearchParamTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchCustomSearchParamTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java similarity index 84% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java index b3bc2fcdbc7..e2b0bd48b4d 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchDistanceTest.java @@ -4,7 +4,7 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.searchparam.MatchUrlService; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; -import ca.uhn.fhir.jpa.util.CoordCalculatorTest; +import ca.uhn.fhir.jpa.util.CoordCalculatorTestUtil; import ca.uhn.fhir.rest.param.TokenParam; import org.hl7.fhir.dstu3.model.Location; import org.junit.jupiter.api.BeforeEach; @@ -32,8 +32,8 @@ public class FhirResourceDaoDstu3SearchDistanceTest extends BaseJpaDstu3Test { @Test public void testNearSearchDistanceNoDistance() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_CHIN; - double longitude = CoordCalculatorTest.LONGITUDE_CHIN; + double latitude = CoordCalculatorTestUtil.LATITUDE_CHIN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_CHIN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); @@ -50,8 +50,8 @@ public class FhirResourceDaoDstu3SearchDistanceTest extends BaseJpaDstu3Test { @Test public void testNearSearchDistanceZero() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_CHIN; - double longitude = CoordCalculatorTest.LONGITUDE_CHIN; + double latitude = CoordCalculatorTestUtil.LATITUDE_CHIN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_CHIN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); @@ -70,17 +70,17 @@ public class FhirResourceDaoDstu3SearchDistanceTest extends BaseJpaDstu3Test { @Test public void testNearSearchApproximate() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); { // In the box - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; SearchParameterMap map = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + ":" + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + ":" + CoordCalculatorTestUtil.LONGITUDE_CHIN + "&" + Location.SP_NEAR_DISTANCE + "=" + bigEnoughDistance + "|http://unitsofmeasure.org|km", myFhirContext.getResourceDefinition("Location")); @@ -88,11 +88,11 @@ public class FhirResourceDaoDstu3SearchDistanceTest extends BaseJpaDstu3Test { assertThat(ids, contains(locId)); } { // Outside the box - double tooSmallDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN / 2; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN / 2; SearchParameterMap map = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + ":" + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + ":" + CoordCalculatorTestUtil.LONGITUDE_CHIN + "&" + Location.SP_NEAR_DISTANCE + "=" + tooSmallDistance + "|http://unitsofmeasure.org|km", myFhirContext.getResourceDefinition("Location")); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java index 4a0221a9fc5..1cc9f81300c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchFtTest.java @@ -17,9 +17,9 @@ import org.hl7.fhir.dstu3.model.Patient; import org.hl7.fhir.dstu3.model.Quantity; import org.hl7.fhir.dstu3.model.StringType; import org.hl7.fhir.instance.model.api.IIdType; -import org.junit.jupiter.api.Test; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Test; import javax.servlet.http.HttpServletRequest; import java.util.List; @@ -29,7 +29,6 @@ import static org.hamcrest.Matchers.contains; import static org.hamcrest.Matchers.containsInAnyOrder; import static org.hamcrest.Matchers.empty; import static org.hamcrest.Matchers.not; -import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; import static org.mockito.Mockito.mock; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchNoFtTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchNoFtTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchNoFtTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchNoFtTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchSqlTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchSqlTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchSqlTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SearchSqlTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java index f3a91c7b305..eb853f1f4be 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3SourceTest.java @@ -20,10 +20,10 @@ import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsInAnyOrder; import static org.hamcrest.Matchers.matchesPattern; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.hamcrest.MatcherAssert.assertThat; import static org.mockito.Mockito.when; @SuppressWarnings({"Duplicates"}) diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3StructureDefinitionTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3StructureDefinitionTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3StructureDefinitionTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3StructureDefinitionTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3TerminologyTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3TerminologyTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3TerminologyTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3TerminologyTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java index fca56980ba9..96db0cabc1e 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3Test.java @@ -5,6 +5,7 @@ import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; import ca.uhn.fhir.jpa.api.model.HistoryCountModeEnum; import ca.uhn.fhir.jpa.dao.BaseHapiFhirDao; +import ca.uhn.fhir.jpa.dao.DaoTestUtils; import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamString; import ca.uhn.fhir.jpa.model.entity.TagTypeEnum; import ca.uhn.fhir.jpa.searchparam.SearchParamConstants; @@ -107,7 +108,6 @@ import static org.hamcrest.Matchers.empty; import static org.hamcrest.Matchers.greaterThan; import static org.hamcrest.Matchers.hasItem; import static org.hamcrest.Matchers.hasSize; -import static org.hamcrest.Matchers.matchesPattern; import static org.hamcrest.Matchers.not; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; @@ -865,7 +865,7 @@ public class FhirResourceDaoDstu3Test extends BaseJpaDstu3Test { myOrganizationDao.delete(orgId, mySrd); fail(); } catch (ResourceVersionConflictException e) { - assertConflictException(e); + DaoTestUtils.assertConflictException(e); } myPatientDao.delete(patId, mySrd); @@ -1007,7 +1007,7 @@ public class FhirResourceDaoDstu3Test extends BaseJpaDstu3Test { myObservationDao.deleteByUrl("Observation?_has:DiagnosticReport:result:identifier=foo|IDENTIFIER", mySrd); fail(); } catch (ResourceVersionConflictException e) { - assertConflictException(e); + DaoTestUtils.assertConflictException(e); } myObservationDao.read(obs1id); @@ -3410,11 +3410,6 @@ public class FhirResourceDaoDstu3Test extends BaseJpaDstu3Test { } - public static void assertConflictException(ResourceVersionConflictException e) { - assertThat(e.getMessage(), matchesPattern( - Msg.code(550) + Msg.code(515) + "Unable to delete [a-zA-Z]+/[0-9]+ because at least one resource has a reference to this resource. First reference found was resource [a-zA-Z]+/[0-9]+ in path [a-zA-Z]+.[a-zA-Z]+")); - } - private static List toStringList(List theUriType) { ArrayList retVal = new ArrayList<>(); for (UriType next : theUriType) { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java index b86ec84111c..adbf0b66a8c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3UpdateTest.java @@ -2,11 +2,11 @@ package ca.uhn.fhir.jpa.dao.dstu3; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; -import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.model.primitive.InstantDt; import ca.uhn.fhir.rest.api.MethodOutcome; +import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import ca.uhn.fhir.rest.param.StringParam; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.ResourceGoneException; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValidateTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValidateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValidateTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValidateTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetMultiVersionTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetMultiVersionTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetMultiVersionTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetMultiVersionTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirResourceDaoDstu3ValueSetTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java index 48333915455..4ecd6a8f73b 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSearchDaoDstu3Test.java @@ -1,22 +1,23 @@ package ca.uhn.fhir.jpa.dao.dstu3; -import static org.hamcrest.Matchers.containsInAnyOrder; -import static org.hamcrest.Matchers.empty; -import static org.hamcrest.MatcherAssert.assertThat; - -import java.util.List; - +import ca.uhn.fhir.jpa.dao.IFulltextSearchSvc; +import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; +import ca.uhn.fhir.rest.api.Constants; import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; +import ca.uhn.fhir.rest.param.StringAndListParam; +import ca.uhn.fhir.rest.param.StringOrListParam; +import ca.uhn.fhir.rest.param.StringParam; import org.hl7.fhir.dstu3.model.Organization; import org.hl7.fhir.dstu3.model.Patient; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; -import ca.uhn.fhir.jpa.dao.IFulltextSearchSvc; -import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; -import ca.uhn.fhir.rest.api.Constants; -import ca.uhn.fhir.rest.param.*; +import java.util.List; + +import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.containsInAnyOrder; +import static org.hamcrest.Matchers.empty; public class FhirSearchDaoDstu3Test extends BaseJpaDstu3Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java index d122a2679ec..914feb5f56a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoDstu3Test.java @@ -10,7 +10,6 @@ import ca.uhn.fhir.jpa.dao.r4.FhirSystemDaoR4; import ca.uhn.fhir.jpa.interceptor.CascadingDeleteInterceptor; import ca.uhn.fhir.jpa.model.entity.ResourceTag; import ca.uhn.fhir.jpa.model.entity.TagTypeEnum; -import ca.uhn.fhir.jpa.provider.SystemProviderDstu2Test; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.model.api.ResourceMetadataKeyEnum; import ca.uhn.fhir.model.primitive.IdDt; @@ -1670,7 +1669,7 @@ public class FhirSystemDaoDstu3Test extends BaseJpaDstu3SystemTest { @Test public void testTransactionFromBundle() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/transaction_link_patient_eve.xml"); + InputStream bundleRes = FhirSystemDaoDstu3Test.class.getResourceAsStream("/transaction_link_patient_eve.xml"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle bundle = myFhirContext.newXmlParser().parseResource(Bundle.class, bundleStr); @@ -1711,7 +1710,7 @@ public class FhirSystemDaoDstu3Test extends BaseJpaDstu3SystemTest { @Test public void testTransactionFromBundle6() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/simone_bundle3.xml"); + InputStream bundleRes = FhirSystemDaoDstu3Test.class.getResourceAsStream("/simone_bundle3.xml"); String bundle = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle output = mySystemDao.transaction(mySrd, myFhirContext.newXmlParser().parseResource(Bundle.class, bundle)); ourLog.info(myFhirContext.newXmlParser().setPrettyPrint(true).encodeResourceToString(output)); @@ -1720,7 +1719,7 @@ public class FhirSystemDaoDstu3Test extends BaseJpaDstu3SystemTest { @Test public void testTransactionFromBundleJosh() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/josh-bundle.json"); + InputStream bundleRes = FhirSystemDaoDstu3Test.class.getResourceAsStream("/josh-bundle.json"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle bundle = myFhirContext.newJsonParser().parseResource(Bundle.class, bundleStr); @@ -2224,7 +2223,7 @@ public class FhirSystemDaoDstu3Test extends BaseJpaDstu3SystemTest { @Disabled public void testTransactionWithBundledValidationSourceAndTarget() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/questionnaire-sdc-profile-example-ussg-fht.xml"); + InputStream bundleRes = FhirSystemDaoDstu3Test.class.getResourceAsStream("/questionnaire-sdc-profile-example-ussg-fht.xml"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle bundle = myFhirContext.newXmlParser().parseResource(Bundle.class, bundleStr); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoTransactionDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoTransactionDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoTransactionDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/dstu3/FhirSystemDaoTransactionDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java similarity index 67% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java index 5d91d330155..694b64af155 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ExpungeHookTest.java @@ -10,18 +10,18 @@ import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; import ca.uhn.test.concurrency.PointcutLatch; -import org.hl7.fhir.dstu3.model.Patient; import org.hl7.fhir.dstu3.model.Meta; +import org.hl7.fhir.dstu3.model.Patient; import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; +import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; -import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; @@ -41,8 +41,8 @@ public class ExpungeHookTest extends BaseJpaDstu3Test { @BeforeEach public void before() { myDaoConfig.setExpungeEnabled(true); - myDaoConfig.setResourceClientIdStrategy(DaoConfig.ClientIdStrategyEnum.ALPHANUMERIC); - myDaoConfig.setAutoCreatePlaceholderReferenceTargets(true); + myDaoConfig.setResourceClientIdStrategy(DaoConfig.ClientIdStrategyEnum.ALPHANUMERIC); + myDaoConfig.setAutoCreatePlaceholderReferenceTargets(true); myInterceptorService.registerAnonymousInterceptor(Pointcut.STORAGE_PRESTORAGE_EXPUNGE_EVERYTHING, myEverythingLatch); myInterceptorService.registerAnonymousInterceptor(Pointcut.STORAGE_PRESTORAGE_EXPUNGE_RESOURCE, myExpungeResourceLatch); } @@ -52,6 +52,8 @@ public class ExpungeHookTest extends BaseJpaDstu3Test { assertTrue(myInterceptorService.unregisterInterceptor(myEverythingLatch)); assertTrue(myInterceptorService.unregisterInterceptor(myExpungeResourceLatch)); myDaoConfig.setExpungeEnabled(new DaoConfig().isExpungeEnabled()); + myDaoConfig.setResourceClientIdStrategy(new DaoConfig().getResourceClientIdStrategy()); + myDaoConfig.setAutoCreatePlaceholderReferenceTargets(new DaoConfig().isAutoCreatePlaceholderReferenceTargets()); } @Test @@ -68,41 +70,41 @@ public class ExpungeHookTest extends BaseJpaDstu3Test { assertPatientGone(id); } - @Test - public void expungeEverythingAndRecreate() throws InterruptedException { - // Create a patient. - Patient thePatient = new Patient(); - thePatient.setId("ABC123"); - Meta theMeta = new Meta(); - theMeta.addProfile("http://hl7.org/fhir/us/core/StructureDefinition/us-core-patient"); - thePatient.setMeta(theMeta); + @Test + public void expungeEverythingAndRecreate() throws InterruptedException { + // Create a patient. + Patient thePatient = new Patient(); + thePatient.setId("ABC123"); + Meta theMeta = new Meta(); + theMeta.addProfile("http://hl7.org/fhir/us/core/StructureDefinition/us-core-patient"); + thePatient.setMeta(theMeta); - IIdType id = myPatientDao.update(thePatient, mySrd).getId(); - assertNotNull(myPatientDao.read(id)); + IIdType id = myPatientDao.update(thePatient, mySrd).getId(); + assertNotNull(myPatientDao.read(id)); - // Expunge it directly. - myPatientDao.delete(id); - ExpungeOptions options = new ExpungeOptions(); - options.setExpungeEverything(true); - options.setExpungeDeletedResources(true); - options.setExpungeOldVersions(true); - myPatientDao.expunge(id.toUnqualifiedVersionless(), options, mySrd); - assertPatientGone(id); - - // Create it a second time. - myPatientDao.update(thePatient, mySrd); - assertNotNull(myPatientDao.read(id)); + // Expunge it directly. + myPatientDao.delete(id); + ExpungeOptions options = new ExpungeOptions(); + options.setExpungeEverything(true); + options.setExpungeDeletedResources(true); + options.setExpungeOldVersions(true); + myPatientDao.expunge(id.toUnqualifiedVersionless(), options, mySrd); + assertPatientGone(id); - // Expunge everything with the service. - myEverythingLatch.setExpectedCount(1); - myExpungeService.expunge(null, null, options, mySrd); - myEverythingLatch.awaitExpected(); - assertPatientGone(id); + // Create it a second time. + myPatientDao.update(thePatient, mySrd); + assertNotNull(myPatientDao.read(id)); - // Create it a third time. - myPatientDao.update(thePatient, mySrd); - assertNotNull(myPatientDao.read(id)); - } + // Expunge everything with the service. + myEverythingLatch.setExpectedCount(1); + myExpungeService.expunge(null, null, options, mySrd); + myEverythingLatch.awaitExpected(); + assertPatientGone(id); + + // Create it a third time. + myPatientDao.update(thePatient, mySrd); + assertNotNull(myPatientDao.read(id)); + } private void assertPatientGone(IIdType theId) { try { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java index 81a51d38ca5..a3f5e0dcea9 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/packages/IgInstallerDstu3Test.java @@ -40,7 +40,7 @@ public class IgInstallerDstu3Test extends BaseJpaDstu3Test { @Autowired private IPackageCacheManager myPackageCacheManager; private Server myServer; - private NpmR4Test.FakeNpmServlet myFakeNpmServlet; + private FakeNpmServlet myFakeNpmServlet; @Autowired private INpmPackageVersionDao myPackageVersionDao; private int myPort; @@ -51,7 +51,7 @@ public class IgInstallerDstu3Test extends BaseJpaDstu3Test { myServer = new Server(0); ServletHandler proxyHandler = new ServletHandler(); - myFakeNpmServlet = new NpmR4Test.FakeNpmServlet(); + myFakeNpmServlet = new FakeNpmServlet(); ServletHolder servletHolder = new ServletHolder(myFakeNpmServlet); proxyHandler.addServletWithMapping(servletHolder, "/*"); myServer.setHandler(proxyHandler); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/packages/NpmDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/packages/NpmDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java index abbd4e45910..15230ffcb45 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/BaseResourceProviderDstu3Test.java @@ -2,7 +2,6 @@ package ca.uhn.fhir.jpa.provider.dstu3; import ca.uhn.fhir.context.support.IValidationSupport; import ca.uhn.fhir.jpa.api.svc.ISearchCoordinatorSvc; -import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.jpa.graphql.GraphQLProvider; import ca.uhn.fhir.jpa.provider.SubscriptionTriggeringProvider; import ca.uhn.fhir.jpa.provider.TerminologyUploaderProvider; @@ -10,6 +9,7 @@ import ca.uhn.fhir.jpa.provider.ValueSetOperationProvider; import ca.uhn.fhir.jpa.search.DatabaseBackedPagingProvider; import ca.uhn.fhir.jpa.searchparam.registry.SearchParamRegistryImpl; import ca.uhn.fhir.jpa.subscription.match.config.WebsocketDispatcherConfig; +import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.narrative.DefaultThymeleafNarrativeGenerator; import ca.uhn.fhir.parser.StrictErrorHandler; import ca.uhn.fhir.rest.api.EncodingEnum; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CompositionDocumentDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CompositionDocumentDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CompositionDocumentDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CompositionDocumentDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java similarity index 92% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java index 995456956cd..c61cedc8692 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/CorsDstu3Test.java @@ -1,16 +1,13 @@ package ca.uhn.fhir.jpa.provider.dstu3; -import static org.junit.jupiter.api.Assertions.assertEquals; - -import java.io.IOException; - import org.apache.commons.io.IOUtils; import org.apache.http.client.methods.CloseableHttpResponse; import org.apache.http.client.methods.HttpGet; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; -import ca.uhn.fhir.util.TestUtil; +import java.io.IOException; + +import static org.junit.jupiter.api.Assertions.assertEquals; public class CorsDstu3Test extends BaseResourceProviderDstu3Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java similarity index 87% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java index f433c6ff320..50af16fa737 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/GraphQLProviderDstu3Test.java @@ -1,5 +1,6 @@ package ca.uhn.fhir.jpa.provider.dstu3; +import ca.uhn.fhir.jpa.provider.GraphQLProviderTestUtil; import ca.uhn.fhir.util.TestUtil; import ca.uhn.fhir.util.UrlUtil; import org.apache.commons.io.IOUtils; @@ -14,8 +15,6 @@ import org.slf4j.LoggerFactory; import java.io.IOException; import java.nio.charset.StandardCharsets; -import static ca.uhn.fhir.jpa.provider.GraphQLR4ProviderTest.DATA_PREFIX; -import static ca.uhn.fhir.jpa.provider.GraphQLR4ProviderTest.DATA_SUFFIX; import static org.junit.jupiter.api.Assertions.assertEquals; public class GraphQLProviderDstu3Test extends BaseResourceProviderDstu3Test { @@ -32,14 +31,14 @@ public class GraphQLProviderDstu3Test extends BaseResourceProviderDstu3Test { try (CloseableHttpResponse response = ourHttpClient.execute(httpGet)) { String resp = IOUtils.toString(response.getEntity().getContent(), StandardCharsets.UTF_8); ourLog.info(resp); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX +"{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX +"{\n" + " \"name\":[{\n" + " \"family\":\"FAM\",\n" + " \"given\":[\"GIVEN1\",\"GIVEN2\"]\n" + " },{\n" + " \"given\":[\"GivenOnly1\",\"GivenOnly2\"]\n" + " }]\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(resp)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(resp)); } } @@ -54,7 +53,7 @@ public class GraphQLProviderDstu3Test extends BaseResourceProviderDstu3Test { try (CloseableHttpResponse response = ourHttpClient.execute(httpGet)) { String resp = IOUtils.toString(response.getEntity().getContent(), StandardCharsets.UTF_8); ourLog.info(resp); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX +"{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX +"{\n" + " \"PatientList\":[{\n" + " \"name\":[{\n" + " \"family\":\"FAM\",\n" + @@ -67,7 +66,7 @@ public class GraphQLProviderDstu3Test extends BaseResourceProviderDstu3Test { " \"given\":[\"GivenOnlyB1\",\"GivenOnlyB2\"]\n" + " }]\n" + " }]\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(resp)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(resp)); } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/PatientEverythingDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/PatientEverythingDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/PatientEverythingDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/PatientEverythingDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/QuestionnaireResourceProviderDstu3.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/QuestionnaireResourceProviderDstu3.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/QuestionnaireResourceProviderDstu3.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/QuestionnaireResourceProviderDstu3.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderCustomSearchParamDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderCustomSearchParamDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderCustomSearchParamDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderCustomSearchParamDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDeleteSqlDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDeleteSqlDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDeleteSqlDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDeleteSqlDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java similarity index 93% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java index 71782f255ee..1f84eb75211 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3BundleTest.java @@ -2,22 +2,17 @@ package ca.uhn.fhir.jpa.provider.dstu3; import ca.uhn.fhir.jpa.model.util.JpaConstants; import ca.uhn.fhir.rest.server.exceptions.NotImplementedOperationException; -import ca.uhn.fhir.util.TestUtil; import org.hl7.fhir.dstu3.model.Bundle; import org.hl7.fhir.dstu3.model.CapabilityStatement; import org.hl7.fhir.dstu3.model.Parameters; import org.hl7.fhir.dstu3.model.PrimitiveType; import org.hl7.fhir.dstu3.model.StringType; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; import java.util.List; import java.util.Optional; -import java.util.stream.Collectors; -import java.util.stream.Stream; import static org.hamcrest.CoreMatchers.containsString; -import static org.hamcrest.CoreMatchers.hasItem; import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemVersionedTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemVersionedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemVersionedTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3CodeSystemVersionedTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ConceptMapTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ConceptMapTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ConceptMapTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ConceptMapTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java similarity index 78% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java index bca55e8f918..cad8eab1139 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3DistanceTest.java @@ -1,6 +1,6 @@ package ca.uhn.fhir.jpa.provider.dstu3; -import ca.uhn.fhir.jpa.util.CoordCalculatorTest; +import ca.uhn.fhir.jpa.util.CoordCalculatorTestUtil; import org.hl7.fhir.dstu3.model.Bundle; import org.hl7.fhir.dstu3.model.Location; import org.hl7.fhir.dstu3.model.PractitionerRole; @@ -24,16 +24,16 @@ public class ResourceProviderDstu3DistanceTest extends BaseResourceProviderDstu3 @Test public void testNearSearchApproximate() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); IIdType locId = ourClient.create().resource(loc).execute().getId().toUnqualifiedVersionless(); { // In the box - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; String url = "/Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTestUtil.LONGITUDE_CHIN + "&" + Location.SP_NEAR_DISTANCE + "=" + bigEnoughDistance + URLEncoder.encode("|http://unitsofmeasure.org|km"); @@ -49,9 +49,9 @@ public class ResourceProviderDstu3DistanceTest extends BaseResourceProviderDstu3 assertEquals(locId.getIdPart(), actual.getEntry().get(0).getResource().getIdElement().getIdPart()); } { // Outside the box - double tooSmallDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN / 2; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN / 2; String url = "/Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTestUtil.LONGITUDE_CHIN + "&" + Location.SP_NEAR_DISTANCE + "=" + tooSmallDistance + URLEncoder.encode("|http://unitsofmeasure.org|km"); @@ -72,8 +72,8 @@ public class ResourceProviderDstu3DistanceTest extends BaseResourceProviderDstu3 @Test public void testNearSearchDistanceNoDistanceChained() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_CHIN; - double longitude = CoordCalculatorTest.LONGITUDE_CHIN; + double latitude = CoordCalculatorTestUtil.LATITUDE_CHIN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_CHIN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); IIdType locId = ourClient.create().resource(loc).execute().getId().toUnqualifiedVersionless(); @@ -100,8 +100,8 @@ public class ResourceProviderDstu3DistanceTest extends BaseResourceProviderDstu3 @Test public void testNearSearchApproximateChained() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); myCaptureQueriesListener.clear(); @@ -112,9 +112,9 @@ public class ResourceProviderDstu3DistanceTest extends BaseResourceProviderDstu3 pr.addLocation().setReference(locId.getValue()); IIdType prId = myPractitionerRoleDao.create(pr).getId().toUnqualifiedVersionless(); { // In the box - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; String url = "PractitionerRole?location." + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTestUtil.LONGITUDE_CHIN + "&" + "location." + Location.SP_NEAR_DISTANCE + "=" + bigEnoughDistance + URLEncoder.encode("|http://unitsofmeasure.org|km"); @@ -133,9 +133,9 @@ public class ResourceProviderDstu3DistanceTest extends BaseResourceProviderDstu3 } { // Outside the box - double tooSmallDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN / 2; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN / 2; String url = "PractitionerRole?location." + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + URLEncoder.encode(":") + CoordCalculatorTestUtil.LONGITUDE_CHIN + "&" + "location." + Location.SP_NEAR_DISTANCE + "=" + tooSmallDistance + URLEncoder.encode("|http://unitsofmeasure.org|km"); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java index 6aa7e35fdfa..cb596eb69a5 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3StructureDefinitionTest.java @@ -4,13 +4,11 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.model.util.JpaConstants; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; -import ca.uhn.fhir.util.TestUtil; import org.hl7.fhir.dstu3.model.IdType; import org.hl7.fhir.dstu3.model.Parameters; import org.hl7.fhir.dstu3.model.StringType; import org.hl7.fhir.dstu3.model.StructureDefinition; import org.hl7.fhir.instance.model.api.IIdType; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; import java.io.IOException; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java index cb807b1e2de..9719a80d81e 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3Test.java @@ -4,7 +4,6 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.dao.data.ISearchDao; import ca.uhn.fhir.jpa.entity.Search; -import ca.uhn.fhir.jpa.provider.r4.ResourceProviderR4Test; import ca.uhn.fhir.jpa.search.SearchCoordinatorSvcImpl; import ca.uhn.fhir.model.api.TemporalPrecisionEnum; import ca.uhn.fhir.model.primitive.InstantDt; @@ -326,7 +325,7 @@ public class ResourceProviderDstu3Test extends BaseResourceProviderDstu3Test { ourRestServer.registerInterceptor(interceptor); try { - String input = IOUtils.toString(ResourceProviderR4Test.class.getResourceAsStream("/bug872-ext-with-hl7-url.json"), Charsets.UTF_8); + String input = IOUtils.toString(ResourceProviderDstu3Test.class.getResourceAsStream("/bug872-ext-with-hl7-url.json"), Charsets.UTF_8); HttpPost post = new HttpPost(ourServerBase + "/Patient/aaa"); post.setEntity(new StringEntity(input, ContentType.APPLICATION_JSON)); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java index 8c6fe5cf8ed..af39c55719f 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetTest.java @@ -4,7 +4,6 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; import ca.uhn.fhir.jpa.dao.data.IResourceTableDao; -import ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest; import ca.uhn.fhir.jpa.entity.TermCodeSystemVersion; import ca.uhn.fhir.jpa.entity.TermConcept; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink.RelationshipTypeEnum; @@ -735,7 +734,7 @@ public class ResourceProviderDstu3ValueSetTest extends BaseResourceProviderDstu3 String url = ourServerBase + "/ValueSet/" + myLocalValueSetId.getIdPart() + "/$validate-code?system=" + - UrlUtil.escapeUrlParam(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM) + + UrlUtil.escapeUrlParam(URL_MY_CODE_SYSTEM) + "&code=AA"; ourLog.info("* Requesting: {}", url); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetVersionedTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetVersionedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetVersionedTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderDstu3ValueSetVersionedTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderExpungeDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderExpungeDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderExpungeDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderExpungeDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java index bd6243a9da4..af6e60e24e5 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderQuestionnaireResponseDstu3Test.java @@ -2,7 +2,6 @@ package ca.uhn.fhir.jpa.provider.dstu3; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; import ca.uhn.fhir.rest.server.interceptor.RequestValidatingInterceptor; -import ca.uhn.fhir.util.TestUtil; import ca.uhn.fhir.validation.IValidatorModule; import ca.uhn.fhir.validation.ResultSeverityEnum; import org.apache.commons.io.IOUtils; @@ -19,9 +18,9 @@ import org.hl7.fhir.dstu3.model.Questionnaire.QuestionnaireItemType; import org.hl7.fhir.dstu3.model.QuestionnaireResponse; import org.hl7.fhir.dstu3.model.QuestionnaireResponse.QuestionnaireResponseStatus; import org.hl7.fhir.instance.model.api.IIdType; -import org.junit.jupiter.api.Test; import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; import java.nio.charset.StandardCharsets; import java.util.Collection; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderR3CodeSystemDesignationTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderR3CodeSystemDesignationTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderR3CodeSystemDesignationTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderR3CodeSystemDesignationTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java similarity index 92% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java index 6a604ff7e77..e55e6f58538 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ResourceProviderSearchModifierDstu3Test.java @@ -1,19 +1,14 @@ package ca.uhn.fhir.jpa.provider.dstu3; -import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; import ca.uhn.fhir.jpa.searchparam.MatchUrlService; import ca.uhn.fhir.jpa.searchparam.ResourceSearch; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.rest.api.server.IBundleProvider; -import org.hl7.fhir.dstu3.model.BodySite; import org.hl7.fhir.dstu3.model.CodeableConcept; import org.hl7.fhir.dstu3.model.Coding; import org.hl7.fhir.dstu3.model.Encounter; import org.hl7.fhir.dstu3.model.Observation; -import org.hl7.fhir.dstu3.model.Patient; -import org.hl7.fhir.dstu3.model.Procedure; import org.hl7.fhir.dstu3.model.Reference; -import org.hl7.fhir.dstu3.model.SearchParameter; import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ServerDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ServerDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ServerDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/ServerDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SubscriptionsDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SubscriptionsDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SubscriptionsDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SubscriptionsDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SystemProviderTransactionSearchDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SystemProviderTransactionSearchDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SystemProviderTransactionSearchDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/provider/dstu3/SystemProviderTransactionSearchDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/PagingMultinodeProviderDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/search/PagingMultinodeProviderDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/PagingMultinodeProviderDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/search/PagingMultinodeProviderDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/searchparam/MatchUrlServiceTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/searchparam/MatchUrlServiceTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/searchparam/MatchUrlServiceTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/searchparam/MatchUrlServiceTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java similarity index 87% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java index d37ed57d3bc..ab8c63287f2 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/FhirDstu3Util.java @@ -1,10 +1,16 @@ package ca.uhn.fhir.jpa.subscription; -import org.hl7.fhir.dstu3.model.*; -import org.hl7.fhir.instance.model.api.*; - import ca.uhn.fhir.rest.api.MethodOutcome; import ca.uhn.fhir.rest.client.api.IGenericClient; +import org.hl7.fhir.dstu3.model.Coding; +import org.hl7.fhir.dstu3.model.Enumerations; +import org.hl7.fhir.dstu3.model.Identifier; +import org.hl7.fhir.dstu3.model.Observation; +import org.hl7.fhir.dstu3.model.Patient; +import org.hl7.fhir.dstu3.model.Subscription; +import org.hl7.fhir.instance.model.api.IBaseCoding; +import org.hl7.fhir.instance.model.api.IBaseMetaType; +import org.hl7.fhir.instance.model.api.IBaseResource; public class FhirDstu3Util { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSenderImplTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSenderImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSenderImplTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSenderImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java index cce4f561e4e..49545d8029e 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/email/EmailSubscriptionDstu3Test.java @@ -2,8 +2,8 @@ package ca.uhn.fhir.jpa.subscription.email; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.provider.dstu3.BaseResourceProviderDstu3Test; -import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.jpa.subscription.match.deliver.email.EmailSenderImpl; +import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.rest.api.MethodOutcome; import ca.uhn.fhir.rest.server.mail.IMailSvc; import ca.uhn.fhir.rest.server.mail.MailConfig; @@ -31,7 +31,7 @@ import java.util.Arrays; import java.util.List; import java.util.function.Consumer; -import static ca.uhn.fhir.jpa.subscription.resthook.RestHookTestDstu3Test.logAllInterceptors; +import static ca.uhn.fhir.jpa.dao.DaoTestUtils.logAllInterceptors; import static org.awaitility.Awaitility.await; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java similarity index 96% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java index 62b8b311b5e..1fe9146d606 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestDstu3Test.java @@ -2,8 +2,8 @@ package ca.uhn.fhir.jpa.subscription.resthook; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.i18n.Msg; -import ca.uhn.fhir.interceptor.api.IInterceptorService; import ca.uhn.fhir.jpa.api.config.DaoConfig; +import ca.uhn.fhir.jpa.dao.DaoTestUtils; import ca.uhn.fhir.jpa.provider.dstu3.BaseResourceProviderDstu3Test; import ca.uhn.fhir.jpa.subscription.NotificationServlet; import ca.uhn.fhir.jpa.subscription.match.matcher.matching.SubscriptionMatchingStrategy; @@ -42,6 +42,7 @@ import org.hl7.fhir.instance.model.api.IBaseResource; import org.hl7.fhir.instance.model.api.IIdType; import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; @@ -56,7 +57,6 @@ import java.util.Collections; import java.util.List; import java.util.concurrent.CountDownLatch; import java.util.concurrent.TimeUnit; -import java.util.stream.Collectors; import static ca.uhn.fhir.util.HapiExtensions.EX_SEND_DELETE_MESSAGES; import static org.awaitility.Awaitility.await; @@ -115,11 +115,11 @@ public class RestHookTestDstu3Test extends BaseResourceProviderDstu3Test { @BeforeEach public void beforeRegisterRestHookListener() { ourLog.info("Before re-registering interceptors"); - logAllInterceptors(myInterceptorRegistry); + DaoTestUtils.logAllInterceptors(myInterceptorRegistry); mySubscriptionTestUtil.registerRestHookInterceptor(); myInterceptorRegistry.registerInterceptor(ourSubscriptionDebugLogInterceptor); ourLog.info("After re-registering interceptors"); - logAllInterceptors(myInterceptorRegistry); + DaoTestUtils.logAllInterceptors(myInterceptorRegistry); } @BeforeEach @@ -241,24 +241,24 @@ public class RestHookTestDstu3Test extends BaseResourceProviderDstu3Test { // Should see 1 subscription notification with authorization header waitForSize(1, ourNotificationServlet.getReceivedAuthorizationHeaders()); - assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); - assertEquals("abc-def", ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); + Assertions.assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); + Assertions.assertEquals("abc-def", ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); ourNotificationServlet.reset(); sendObservation(code, "SNOMED-CT"); // Should see 1 subscription notification with authorization header waitForSize(1, ourNotificationServlet.getReceivedAuthorizationHeaders()); - assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); - assertEquals("abc-def", ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); + Assertions.assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); + Assertions.assertEquals("abc-def", ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); ourNotificationServlet.reset(); Observation observationTemp3 = sendObservation(code, "SNOMED-CT"); /// Should see 1 subscription notification with authorization header waitForSize(1, ourNotificationServlet.getReceivedAuthorizationHeaders()); - assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); - assertEquals("abc-def", ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); + Assertions.assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); + Assertions.assertEquals("abc-def", ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); ourNotificationServlet.reset(); Observation observation3 = ourClient.read(Observation.class, observationTemp3.getId()); @@ -271,7 +271,7 @@ public class RestHookTestDstu3Test extends BaseResourceProviderDstu3Test { // Should see 2 subscription notifications with and without authorization header waitForSize(1, ourNotificationServlet.getReceivedAuthorizationHeaders()); - assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); + Assertions.assertEquals(1, ourNotificationServlet.getReceivedNotificationCount()); assertNull(ourNotificationServlet.getReceivedAuthorizationHeaders().get(0)); ourNotificationServlet.reset(); } @@ -685,16 +685,6 @@ public class RestHookTestDstu3Test extends BaseResourceProviderDstu3Test { } } - public static void logAllInterceptors(IInterceptorService theInterceptorRegistry) { - List allInterceptors = theInterceptorRegistry.getAllRegisteredInterceptors(); - String interceptorList = allInterceptors - .stream() - .map(t -> t.getClass().toString()) - .sorted() - .collect(Collectors.joining("\n * ")); - ourLog.info("Registered interceptors:\n * {}", interceptorList); - } - @BeforeAll public static void startListenerServer() throws Exception { ourListenerRestServer = new RestfulServer(FhirContext.forDstu3Cached()); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/SubscriptionTriggeringDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/SubscriptionTriggeringDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/SubscriptionTriggeringDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/SubscriptionTriggeringDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java similarity index 95% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java index 45f988c04d3..6d2efe18cbf 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaDstu3Test.java @@ -8,7 +8,12 @@ import ca.uhn.fhir.rest.api.MethodOutcome; import org.eclipse.jetty.websocket.api.Session; import org.eclipse.jetty.websocket.client.ClientUpgradeRequest; import org.eclipse.jetty.websocket.client.WebSocketClient; -import org.hl7.fhir.dstu3.model.*; +import org.hl7.fhir.dstu3.model.CodeableConcept; +import org.hl7.fhir.dstu3.model.Coding; +import org.hl7.fhir.dstu3.model.Observation; +import org.hl7.fhir.dstu3.model.Patient; +import org.hl7.fhir.dstu3.model.Reference; +import org.hl7.fhir.dstu3.model.Subscription; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; @@ -19,8 +24,8 @@ import java.net.URI; import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; -import static org.hamcrest.Matchers.contains; import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.contains; // This is currently disabled as the criteria mechanism was a non-standard experiment @Disabled diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdDstu3Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java similarity index 94% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java index 2a82ff5ccf1..6bfdf7a289c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIntegrationDstu3Test.java @@ -2,8 +2,8 @@ package ca.uhn.fhir.jpa.term; import ca.uhn.fhir.context.support.IValidationSupport; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.jpa.term.api.ITermLoaderSvc; +import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import com.google.common.collect.Lists; import org.hl7.fhir.dstu3.model.CodeType; import org.hl7.fhir.dstu3.model.Coding; @@ -67,7 +67,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testExpandWithPropertyCoding() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); // Search by code @@ -120,7 +120,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testStoreAndProcessDeferred() throws IOException { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveDeferred(); @@ -131,7 +131,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testExpandWithPropertyString() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); ValueSet input = new ValueSet(); @@ -153,7 +153,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testLookupWithProperties() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); IValidationSupport.LookupCodeResult result = myCodeSystemDao.lookupCode(new StringType("10013-1"), new StringType(ITermLoaderSvc.LOINC_URI), null, mySrd); @@ -183,7 +183,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testLookupWithProperties2() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); IValidationSupport.LookupCodeResult result = myCodeSystemDao.lookupCode(new StringType("10013-1"), new StringType(ITermLoaderSvc.LOINC_URI), null, mySrd); @@ -201,7 +201,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testLookupWithPropertiesExplicit() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); IValidationSupport.LookupCodeResult result = myCodeSystemDao.lookupCode(new StringType("10013-1"), new StringType(ITermLoaderSvc.LOINC_URI), null, mySrd); @@ -224,7 +224,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testValidateCodeFound() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveDeferred(); myTerminologyDeferredStorageSvc.saveDeferred(); @@ -238,7 +238,7 @@ public class TerminologyLoaderSvcIntegrationDstu3Test extends BaseJpaDstu3Test { @Test public void testValidateCodeNotFound() throws Exception { ZipCollectionBuilder files = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesToZip(files); + TermTestUtil.addLoincMandatoryFilesToZip(files); myLoader.loadLoinc(files.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveDeferred(); myTerminologyDeferredStorageSvc.saveDeferred(); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java index 47ed7d10463..3f018ec2696 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplDstu3Test.java @@ -5,13 +5,13 @@ import ca.uhn.fhir.context.support.IValidationSupport; import ca.uhn.fhir.context.support.ValidationSupportContext; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.jpa.entity.TermCodeSystem; import ca.uhn.fhir.jpa.entity.TermCodeSystemVersion; import ca.uhn.fhir.jpa.entity.TermConcept; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink.RelationshipTypeEnum; import ca.uhn.fhir.jpa.model.entity.ResourceTable; +import ca.uhn.fhir.jpa.test.BaseJpaDstu3Test; import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import ca.uhn.fhir.rest.api.server.storage.TransactionDetails; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/validator/AttachmentUtilTest.java b/hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/validator/AttachmentUtilTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/validator/AttachmentUtilTest.java rename to hapi-fhir-jpaserver-test-dstu3/src/test/java/ca/uhn/fhir/validator/AttachmentUtilTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/batch-error.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/batch-error.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/batch-error.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/batch-error.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug-410-bundle.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug-410-bundle.xml similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug-410-bundle.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug-410-bundle.xml index 4b6f1ab68bc..115374b00ca 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug-410-bundle.xml +++ b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug-410-bundle.xml @@ -1,4 +1,4 @@ - + @@ -101,6 +101,7 @@ + diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug1044-bundle.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug1044-bundle.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug1044-bundle.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug1044-bundle.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug147-bundle-dstu3.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug147-bundle-dstu3.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug147-bundle-dstu3.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/bug147-bundle-dstu3.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bundle-dstu3.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/bundle-dstu3.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bundle-dstu3.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/bundle-dstu3.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/document-bundle-dstu3.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/document-bundle-dstu3.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/document-bundle-dstu3.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/document-bundle-dstu3.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/document-father-dstu3.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/document-father-dstu3.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/document-father-dstu3.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/document-father-dstu3.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/Reilly_Libby_73.json.gz b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/Reilly_Libby_73.json.gz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/Reilly_Libby_73.json.gz rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/Reilly_Libby_73.json.gz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/bundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/bundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/duplicate-conditional-create.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/duplicate-conditional-create.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/duplicate-conditional-create.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/duplicate-conditional-create.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc01-cs-yesnounk.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc01-cs-yesnounk.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc01-cs-yesnounk.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc01-cs-yesnounk.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-cs-binderrecommend.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-cs-binderrecommend.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-cs-binderrecommend.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-cs-binderrecommend.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-questionnaire.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-questionnaire.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-questionnaire.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-questionnaire.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-questionnaireresponse.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-questionnaireresponse.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-questionnaireresponse.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-questionnaireresponse.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-vs-binderrecommend.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-vs-binderrecommend.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-vs-binderrecommend.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-vs-binderrecommend.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-vs-fmcyesno.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-vs-fmcyesno.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/fmc03-vs-fmcyesno.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/fmc03-vs-fmcyesno.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/iar/CodeSystem-iar-citizenship-status.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/iar/CodeSystem-iar-citizenship-status.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/iar/CodeSystem-iar-citizenship-status.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/iar/CodeSystem-iar-citizenship-status.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/iar/ValueSet-iar-citizenship-status.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/iar/ValueSet-iar-citizenship-status.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/iar/ValueSet-iar-citizenship-status.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/iar/ValueSet-iar-citizenship-status.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/nl/LandISOCodelijst-2.16.840.1.113883.2.4.3.11.60.40.2.20.5.2--20171231000000.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/nl/LandISOCodelijst-2.16.840.1.113883.2.4.3.11.60.40.2.20.5.2--20171231000000.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/nl/LandISOCodelijst-2.16.840.1.113883.2.4.3.11.60.40.2.20.5.2--20171231000000.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/nl/LandISOCodelijst-2.16.840.1.113883.2.4.3.11.60.40.2.20.5.2--20171231000000.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/episodeofcare-bundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/episodeofcare-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/episodeofcare-bundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/episodeofcare-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/location-bundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/location-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/location-bundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/location-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/organization-bundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/organization-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/organization-bundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/organization-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/patient-bundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/patient-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/patient-bundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/patient-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/practitioner-bundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/practitioner-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/no-store-header/practitioner-bundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/no-store-header/practitioner-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/profile-differential-patient-dstu3.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/profile-differential-patient-dstu3.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/profile-differential-patient-dstu3.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/profile-differential-patient-dstu3.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/slow_bundle.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/slow_bundle.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3/slow_bundle.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3/slow_bundle.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_codesystem_complete.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3_codesystem_complete.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_codesystem_complete.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3_codesystem_complete.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_custom_resource_patient.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3_custom_resource_patient.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_custom_resource_patient.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3_custom_resource_patient.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_transaction2.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3_transaction2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_transaction2.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/dstu3_transaction2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/mihin-resource-dstu3.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/mihin-resource-dstu3.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/mihin-resource-dstu3.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/mihin-resource-dstu3.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/oruBundle.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/oruBundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/oruBundle.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/oruBundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.10.tgz b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.10.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.10.tgz rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.10.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.9.tgz b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.9.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.9.tgz rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017-1.3.9.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/packages/nictiz.fhir.nl.stu3.zib2017.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/questionnaire_dstu3.xml b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/questionnaire_dstu3.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/questionnaire_dstu3.xml rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/questionnaire_dstu3.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sd-david-dhtest7.json b/hapi-fhir-jpaserver-test-dstu3/src/test/resources/sd-david-dhtest7.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sd-david-dhtest7.json rename to hapi-fhir-jpaserver-test-dstu3/src/test/resources/sd-david-dhtest7.json diff --git a/hapi-fhir-jpaserver-test-r4/pom.xml b/hapi-fhir-jpaserver-test-r4/pom.xml new file mode 100644 index 00000000000..7dad2347575 --- /dev/null +++ b/hapi-fhir-jpaserver-test-r4/pom.xml @@ -0,0 +1,113 @@ + + + 4.0.0 + + ca.uhn.hapi.fhir + hapi-deployable-pom + 6.2.0-PRE2-SNAPSHOT + ../hapi-deployable-pom/pom.xml + + + jar + + HAPI FHIR JPA Server Test R4 + hapi-fhir-jpaserver-test-r4 + + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-utilities + ${project.version} + test + + + + + + + org.apache.maven.plugins + maven-failsafe-plugin + + + 1 + false + alphabetical + + **/*IT.java + + false + + + + + integration-test + verify + + + + + + org.junit.jupiter + junit-jupiter-engine + ${junit_version} + + + + + org.apache.maven.plugins + maven-surefire-plugin + + alphabetical + @{argLine} ${surefire_jvm_args} + 0.6C + *StressTest* + ${skipFailsafe} + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + true + + + + + + + + NOPARALLEL + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + + **/stresstest/* + + + + + + + + CI + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + alphabetical + + + + + + + + diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java index 4ea71ae5704..24e3b970916 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/client/ClientThreadedCapabilitiesTest.java @@ -27,7 +27,6 @@ import org.junit.jupiter.api.extension.RegisterExtension; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import java.io.IOException; import java.util.Collection; import java.util.Date; import java.util.Random; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java index b3938300da6..c0dd540b844 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/Batch2CoordinatorIT.java @@ -17,10 +17,10 @@ import ca.uhn.fhir.batch2.coordinator.JobDefinitionRegistry; import ca.uhn.fhir.batch2.model.ChunkOutcome; import ca.uhn.fhir.batch2.model.JobDefinition; import ca.uhn.fhir.batch2.model.JobInstance; -import ca.uhn.fhir.batch2.models.JobInstanceFetchRequest; import ca.uhn.fhir.batch2.model.JobInstanceStartRequest; import ca.uhn.fhir.batch2.model.JobWorkNotificationJsonMessage; import ca.uhn.fhir.batch2.model.StatusEnum; +import ca.uhn.fhir.batch2.models.JobInstanceFetchRequest; import ca.uhn.fhir.jpa.batch.models.Batch2JobStartResponse; import ca.uhn.fhir.jpa.subscription.channel.api.ChannelConsumerSettings; import ca.uhn.fhir.jpa.subscription.channel.api.IChannelFactory; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/JobInstanceRepositoryTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/JobInstanceRepositoryTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/JobInstanceRepositoryTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/JobInstanceRepositoryTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/JpaJobPersistenceImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/JpaJobPersistenceImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/batch2/JpaJobPersistenceImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/batch2/JpaJobPersistenceImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java index 1c52b25365b..0f08c55fa97 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/BinaryAccessProviderTest.java @@ -6,20 +6,17 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.interceptor.api.IInterceptorBroadcaster; import ca.uhn.fhir.jpa.api.dao.DaoRegistry; import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; - import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; -import ca.uhn.fhir.jpa.binary.provider.BinaryAccessProvider; import ca.uhn.fhir.jpa.binary.api.IBinaryStorageSvc; import ca.uhn.fhir.jpa.binary.api.StoredDetails; +import ca.uhn.fhir.jpa.binary.provider.BinaryAccessProvider; import ca.uhn.fhir.mdm.util.MessageHelper; import ca.uhn.fhir.rest.server.RestfulServer; -import org.hl7.fhir.instance.model.api.IBaseResource; -import org.hl7.fhir.r4.model.DocumentReference; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.servlet.ServletRequestDetails; - +import org.hl7.fhir.instance.model.api.IBaseResource; +import org.hl7.fhir.r4.model.DocumentReference; import org.hl7.fhir.r4.model.StringType; - import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/DatabaseBlobBinaryStorageSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/DatabaseBlobBinaryStorageSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/DatabaseBlobBinaryStorageSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/DatabaseBlobBinaryStorageSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java similarity index 95% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java index 4d1eddd3ef7..f41401f47a0 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/FilesystemBinaryStorageSvcImplTest.java @@ -18,7 +18,10 @@ import java.io.ByteArrayOutputStream; import java.io.File; import java.io.IOException; -import static org.junit.jupiter.api.Assertions.*; +import static org.junit.jupiter.api.Assertions.assertArrayEquals; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertNotNull; +import static org.junit.jupiter.api.Assertions.fail; public class FilesystemBinaryStorageSvcImplTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/NullBinaryStorageSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/NullBinaryStorageSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/binstore/NullBinaryStorageSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/binstore/NullBinaryStorageSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/BulkDataExportProviderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/BulkDataExportProviderTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/BulkDataExportProviderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/BulkDataExportProviderTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt/svc/BulkDataImportSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/BulkImportR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/BulkImportR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/BulkImportR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/BulkImportR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/ConsumeFilesStepR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/ConsumeFilesStepR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/ConsumeFilesStepR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/bulk/imprt2/ConsumeFilesStepR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java index 8099a04b045..c4c298cebce 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/cache/ResourceChangeListenerRegistryImplIT.java @@ -2,8 +2,8 @@ package ca.uhn.fhir.jpa.cache; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.interceptor.api.HookParams; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.model.primitive.IdDt; import ca.uhn.fhir.rest.param.DateRangeParam; import ca.uhn.fhir.rest.param.TokenParam; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java index 05581631783..85b6ae69426 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/cache/ResourceVersionCacheSvcTest.java @@ -1,7 +1,7 @@ package ca.uhn.fhir.jpa.cache; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.Enumerations; import org.hl7.fhir.r4.model.Patient; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirDaoTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirDaoTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirDaoTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirDaoTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java index 26d7cf538da..64681ca6ef2 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/BaseHapiFhirResourceDaoTest.java @@ -38,7 +38,6 @@ import org.mockito.Mockito; import org.mockito.junit.jupiter.MockitoExtension; import javax.persistence.EntityManager; - import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java similarity index 94% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java index dea24ca509b..9c57773423b 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/JpaPersistedResourceValidationSupportTest.java @@ -25,7 +25,6 @@ import ca.uhn.fhir.context.support.IValidationSupport; import ca.uhn.fhir.jpa.api.dao.DaoRegistry; import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; import ca.uhn.fhir.jpa.term.api.ITermReadSvc; -import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; import com.github.benmanes.caffeine.cache.Cache; import org.hl7.fhir.instance.model.api.IBaseResource; import org.hl7.fhir.r4.model.CodeSystem; @@ -43,8 +42,6 @@ import java.util.function.Function; import static org.hl7.fhir.common.hapi.validation.support.ValidationConstants.LOINC_LOW; import static org.junit.jupiter.api.Assertions.assertNull; -import static org.junit.jupiter.api.Assertions.assertThrows; -import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.ArgumentMatchers.isA; import static org.mockito.Mockito.never; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/TolerantJsonParserR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/TolerantJsonParserR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/TolerantJsonParserR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/TolerantJsonParserR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/TransactionProcessorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/TransactionProcessorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/TransactionProcessorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/TransactionProcessorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/DeleteExpungeDaoTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/expunge/DeleteExpungeDaoTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/DeleteExpungeDaoTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/expunge/DeleteExpungeDaoTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ResourceTableFKProviderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ResourceTableFKProviderTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ResourceTableFKProviderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/expunge/ResourceTableFKProviderTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java index da24c44bde0..dab26fa6c77 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/index/IdHelperServiceTest.java @@ -28,7 +28,7 @@ import java.util.function.Function; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.hasSize; -import static org.junit.Assert.assertEquals; +import static org.junit.jupiter.api.Assertions.assertEquals; import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.Mockito.when; @@ -145,8 +145,8 @@ public class IdHelperServiceTest { for (String id : patientIdsToResolve) { Assertions.assertTrue(map.containsKey(id)); } - Assertions.assertEquals(red, map.get("RED")); - Assertions.assertEquals(blue, map.get("BLUE")); + assertEquals(red, map.get("RED")); + assertEquals(blue, map.get("BLUE")); } @Test diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseComboParamsR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseComboParamsR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseComboParamsR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseComboParamsR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseJpaR4SystemTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseJpaR4SystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseJpaR4SystemTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/BaseJpaR4SystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/BasePartitioningR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/BasePartitioningR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/BasePartitioningR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/BasePartitioningR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/ChainingR4SearchTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/ChainingR4SearchTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/ChainingR4SearchTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/ChainingR4SearchTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java index 67df82c6dc6..e5b741287ef 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/ConsentEventsDaoR4Test.java @@ -5,9 +5,9 @@ import ca.uhn.fhir.interceptor.api.IAnonymousInterceptor; import ca.uhn.fhir.interceptor.api.IPointcut; import ca.uhn.fhir.interceptor.api.Pointcut; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.config.TestR4Config; import ca.uhn.fhir.jpa.entity.Search; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.config.TestR4Config; import ca.uhn.fhir.rest.api.SortOrderEnum; import ca.uhn.fhir.rest.api.SortSpec; import ca.uhn.fhir.rest.api.server.IBundleProvider; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java index 4c7bc57365b..ef8046b9f59 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/CustomObservationR4.java @@ -20,12 +20,11 @@ package ca.uhn.fhir.jpa.dao.r4; * #L% */ -import org.hl7.fhir.r4.model.Observation; -import org.hl7.fhir.r4.model.StringType; - import ca.uhn.fhir.model.api.annotation.Child; import ca.uhn.fhir.model.api.annotation.Extension; import ca.uhn.fhir.model.api.annotation.ResourceDef; +import org.hl7.fhir.r4.model.Observation; +import org.hl7.fhir.r4.model.StringType; @ResourceDef(name = "Observation", profile = CustomObservationR4.PROFILE) public class CustomObservationR4 extends Observation { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCreatePlaceholdersR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCreatePlaceholdersR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCreatePlaceholdersR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCreatePlaceholdersR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCustomTypeR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCustomTypeR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCustomTypeR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoCustomTypeR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoDocumentR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoDocumentR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoDocumentR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoDocumentR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java index 9744058c53b..da591c5d757 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CacheWarmingTest.java @@ -21,7 +21,6 @@ import org.slf4j.LoggerFactory; import java.util.ArrayList; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; public class FhirResourceDaoR4CacheWarmingTest extends BaseJpaR4Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CodeSystemTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CodeSystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CodeSystemTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CodeSystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboNonUniqueParamTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboNonUniqueParamTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboNonUniqueParamTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboNonUniqueParamTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamIT.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamIT.java index dff7aa0e2f4..ebca1497ff6 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ComboUniqueParamIT.java @@ -62,9 +62,9 @@ import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; -public class FhirResourceDaoR4ComboUniqueParamTest extends BaseComboParamsR4Test { +public class FhirResourceDaoR4ComboUniqueParamIT extends BaseComboParamsR4Test { - private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(FhirResourceDaoR4ComboUniqueParamTest.class); + private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(FhirResourceDaoR4ComboUniqueParamIT.class); @AfterEach public void purgeUniqueIndexes() { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConceptMapTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConceptMapTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConceptMapTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConceptMapTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConcurrentWriteTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConcurrentWriteTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConcurrentWriteTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ConcurrentWriteTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ContainedTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ContainedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ContainedTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ContainedTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java index 0aab59287ab..c16c9be98d2 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4CreateTest.java @@ -3,7 +3,6 @@ package ca.uhn.fhir.jpa.dao.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; -import ca.uhn.fhir.jpa.test.config.TestR4Config; import ca.uhn.fhir.jpa.model.entity.ModelConfig; import ca.uhn.fhir.jpa.model.entity.NormalizedQuantitySearchLevel; import ca.uhn.fhir.jpa.model.entity.ResourceHistoryTable; @@ -16,6 +15,7 @@ import ca.uhn.fhir.jpa.model.util.UcumServiceUtil; import ca.uhn.fhir.jpa.partition.SystemRequestDetails; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; +import ca.uhn.fhir.jpa.test.config.TestR4Config; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.rest.param.QuantityParam; import ca.uhn.fhir.rest.param.ReferenceParam; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4DeleteTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4DeleteTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4DeleteTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4DeleteTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java index e4e3a47a66b..89099d3d5e8 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ExternalReferenceTest.java @@ -1,14 +1,5 @@ package ca.uhn.fhir.jpa.dao.r4; -import static org.hamcrest.Matchers.contains; -import static org.hamcrest.Matchers.empty; -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.hamcrest.MatcherAssert.assertThat; -import static org.junit.jupiter.api.Assertions.fail; - -import java.util.HashSet; -import java.util.Set; - import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; @@ -22,6 +13,15 @@ import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import java.util.HashSet; +import java.util.Set; + +import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.contains; +import static org.hamcrest.Matchers.empty; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.fail; + public class FhirResourceDaoR4ExternalReferenceTest extends BaseJpaR4Test { @BeforeEach diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4FilterTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4FilterTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4FilterTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4FilterTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4HistoryRewriteTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4HistoryRewriteTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4HistoryRewriteTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4HistoryRewriteTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InlineResourceModeTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InlineResourceModeTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InlineResourceModeTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InlineResourceModeTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InterceptorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java index 96cb680956e..09e40087bf4 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4InvalidSubscriptionTest.java @@ -3,8 +3,8 @@ package ca.uhn.fhir.jpa.dao.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.dao.BaseHapiFhirDao; -import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; +import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.Subscription; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4MetaTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4MetaTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4MetaTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4MetaTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4QueryCountTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4QueryCountTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4QueryCountTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4QueryCountTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ReferentialIntegrityTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ReferentialIntegrityTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ReferentialIntegrityTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ReferentialIntegrityTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchCustomSearchParamTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchCustomSearchParamTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchCustomSearchParamTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchCustomSearchParamTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java similarity index 76% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java index d5328e9362b..0b2b4ba5daa 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchDistanceTest.java @@ -3,7 +3,7 @@ package ca.uhn.fhir.jpa.dao.r4; import ca.uhn.fhir.jpa.searchparam.MatchUrlService; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; -import ca.uhn.fhir.jpa.util.CoordCalculatorTest; +import ca.uhn.fhir.jpa.util.CoordCalculatorTestUtil; import org.hl7.fhir.r4.model.Location; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; @@ -27,8 +27,8 @@ public class FhirResourceDaoR4SearchDistanceTest extends BaseJpaR4Test { @Test public void testNearSearchDistanceNoDistance() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_CHIN; - double longitude = CoordCalculatorTest.LATITUDE_CHIN; + double latitude = CoordCalculatorTestUtil.LATITUDE_CHIN; + double longitude = CoordCalculatorTestUtil.LATITUDE_CHIN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); @@ -45,8 +45,8 @@ public class FhirResourceDaoR4SearchDistanceTest extends BaseJpaR4Test { @Test public void testNearSearchDistanceZero() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_CHIN; - double longitude = CoordCalculatorTest.LATITUDE_CHIN; + double latitude = CoordCalculatorTestUtil.LATITUDE_CHIN; + double longitude = CoordCalculatorTestUtil.LATITUDE_CHIN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); @@ -73,30 +73,30 @@ public class FhirResourceDaoR4SearchDistanceTest extends BaseJpaR4Test { @Test public void testNearSearchApproximate() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); { // In the box - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; SearchParameterMap map = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" - + CoordCalculatorTest.LONGITUDE_CHIN + "|" + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + bigEnoughDistance, myFhirContext.getResourceDefinition("Location")); List ids = toUnqualifiedVersionlessIdValues(myLocationDao.search(map)); assertThat(ids, contains(locId)); } { // Outside the box - double tooSmallDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN / 2; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN / 2; SearchParameterMap map = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" - + CoordCalculatorTest.LONGITUDE_CHIN + "|" + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + tooSmallDistance, myFhirContext.getResourceDefinition("Location")); List ids = toUnqualifiedVersionlessIdValues(myLocationDao.search(map)); @@ -108,29 +108,29 @@ public class FhirResourceDaoR4SearchDistanceTest extends BaseJpaR4Test { @Test public void testNearSearchApproximateNearAntiMeridian() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_TAVEUNI; - double longitude = CoordCalculatorTest.LONGITIDE_TAVEUNI; + double latitude = CoordCalculatorTestUtil.LATITUDE_TAVEUNI; + double longitude = CoordCalculatorTestUtil.LONGITIDE_TAVEUNI; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); String locId = myLocationDao.create(loc).getId().toUnqualifiedVersionless().getValue(); { // We match even when the box crosses the anti-meridian - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_TAVEUNI; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_TAVEUNI; SearchParameterMap map = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_TAVEUNI + "|" - + CoordCalculatorTest.LONGITIDE_TAVEUNI + "|" + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_TAVEUNI + "|" + + CoordCalculatorTestUtil.LONGITIDE_TAVEUNI + "|" + bigEnoughDistance, myFhirContext.getResourceDefinition("Location")); List ids = toUnqualifiedVersionlessIdValues(myLocationDao.search(map)); assertThat(ids, contains(locId)); } { // We don't match outside a box that crosses the anti-meridian - double tooSmallDistance = CoordCalculatorTest.DISTANCE_TAVEUNI; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_TAVEUNI; SearchParameterMap map = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" - + CoordCalculatorTest.LONGITUDE_CHIN + "|" + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + tooSmallDistance, myFhirContext.getResourceDefinition("Location")); List ids = toUnqualifiedVersionlessIdValues(myLocationDao.search(map)); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchFtTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchFtTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchFtTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchFtTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchIncludeTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchIncludeTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchIncludeTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchIncludeTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchMissingTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchMissingTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchMissingTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchMissingTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoFtTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoFtTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoFtTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoFtTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoHashesTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoHashesTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoHashesTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchNoHashesTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchOptimizedTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchOptimizedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchOptimizedTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchOptimizedTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchPageExpiryTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchPageExpiryTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchPageExpiryTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchPageExpiryTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchSqlTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchSqlTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchSqlTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchSqlTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchWithHSearchDisabledTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchWithHSearchDisabledTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchWithHSearchDisabledTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SearchWithHSearchDisabledTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SelectiveUpdateTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SelectiveUpdateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SelectiveUpdateTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SelectiveUpdateTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SortTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SortTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SortTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SortTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java index 496ec5ffb36..10d48aa96ad 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4SourceTest.java @@ -20,10 +20,10 @@ import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsInAnyOrder; import static org.hamcrest.Matchers.matchesPattern; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.hamcrest.MatcherAssert.assertThat; import static org.mockito.Mockito.when; @SuppressWarnings({"Duplicates"}) diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StandardQueriesNoFTTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StandardQueriesNoFTTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StandardQueriesNoFTTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StandardQueriesNoFTTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StructureDefinitionTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StructureDefinitionTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StructureDefinitionTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4StructureDefinitionTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TagsTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TagsTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TagsTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TagsTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java similarity index 87% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java index f330f668d4d..9a1f40f415e 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4TerminologyTest.java @@ -10,6 +10,7 @@ import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink.RelationshipTypeEnum; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.jpa.term.TermReindexingSvcImpl; +import ca.uhn.fhir.jpa.term.TermTestUtil; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.parser.IParser; import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; @@ -60,8 +61,6 @@ import static org.junit.jupiter.api.Assertions.fail; @SuppressWarnings("Duplicates") public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { - public static final String URL_MY_CODE_SYSTEM = "http://example.com/my_code_system"; - public static final String URL_MY_VALUE_SET = "http://example.com/my_value_set"; private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(FhirResourceDaoR4TerminologyTest.class); @@ -80,7 +79,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { private CodeSystem createExternalCs() { CodeSystem codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setVersion("SYSTEM VERSION"); codeSystem.setContent(CodeSystemContentMode.NOTPRESENT); IIdType id = myCodeSystemDao.create(codeSystem, mySrd).getId().toUnqualified(); @@ -119,7 +118,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { TermConcept childCA = new TermConcept(cs, "childCA").setDisplay("Child CA"); parentC.addChild(childCA, RelationshipTypeEnum.ISA); - myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); + myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), TermTestUtil.URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); return codeSystem; }); } @@ -132,7 +131,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { private CodeSystem createExternalCsDogs() { CodeSystem codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setVersion("SYSTEM VERSION"); codeSystem.setContent(CodeSystemContentMode.NOTPRESENT); IIdType id = myCodeSystemDao.create(codeSystem, mySrd).getId().toUnqualified(); @@ -158,14 +157,14 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { TermConcept beagle = new TermConcept(cs, "beagle").setDisplay("Beagle"); dogs.addChild(beagle, RelationshipTypeEnum.ISA); - myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); + myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), TermTestUtil.URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); return codeSystem; }); } private void createExternalCsLarge() { CodeSystem codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setVersion("SYSTEM VERSION"); codeSystem.setContent(CodeSystemContentMode.NOTPRESENT); IIdType id = myCodeSystemDao.create(codeSystem, mySrd).getId().toUnqualified(); @@ -191,7 +190,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { parentB.addChild(childI, RelationshipTypeEnum.ISA); } - myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); + myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), TermTestUtil.URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); myTerminologyDeferredStorageSvc.saveAllDeferred(); } @@ -214,12 +213,12 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { public void testCodeSystemCreateDuplicateFails() { // No version. CodeSystem codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setContent(CodeSystemContentMode.COMPLETE); IIdType id = myCodeSystemDao.create(codeSystem, mySrd).getId().toUnqualified(); codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setContent(CodeSystemContentMode.COMPLETE); try { myCodeSystemDao.create(codeSystem, mySrd); @@ -230,13 +229,13 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { // With version. codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setVersion("1"); codeSystem.setContent(CodeSystemContentMode.COMPLETE); id = myCodeSystemDao.create(codeSystem, mySrd).getId().toUnqualified(); codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setVersion("1"); codeSystem.setContent(CodeSystemContentMode.COMPLETE); try { @@ -252,7 +251,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { public void testCodeSystemWithDefinedCodes() { //@formatter:off CodeSystem codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setContent(CodeSystemContentMode.COMPLETE); codeSystem .addConcept().setCode("A").setDisplay("Code A") @@ -296,7 +295,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter(); include.addFilter().setOp(FilterOperator.ISA).setValue("childAA"); @@ -313,7 +312,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { CodeSystem codeSystem = createExternalCsDogs(); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose() .addInclude() .setSystem(codeSystem.getUrl()) @@ -341,7 +340,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { CodeSystem codeSystem = createExternalCsDogs(); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose() .addInclude() .setSystem(codeSystem.getUrl()) @@ -371,7 +370,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { CodeSystem codeSystem = createExternalCsDogs(); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose() .addInclude() .setSystem(codeSystem.getUrl()) @@ -401,7 +400,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { CodeSystem codeSystem = createExternalCsDogs(); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose().addInclude().setSystem(codeSystem.getUrl()); myValueSetDao.create(valueSet, mySrd); @@ -419,7 +418,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { CodeSystem codeSystem = createExternalCsDogs(); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose() .addInclude() .setSystem(codeSystem.getUrl()) @@ -450,7 +449,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setProperty("display").setOp(FilterOperator.EQUAL).setValue("parent a"); ValueSet result = myValueSetDao.expand(vs, null); logAndValidateValueSet(result); @@ -459,7 +458,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { vs = new ValueSet(); include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setProperty("display").setOp(FilterOperator.EQUAL).setValue("pare"); result = myValueSetDao.expand(vs, null); logAndValidateValueSet(result); @@ -468,7 +467,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { vs = new ValueSet(); include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setProperty("display:exact").setOp(FilterOperator.EQUAL).setValue("pare"); result = myValueSetDao.expand(vs, null); logAndValidateValueSet(result); @@ -483,10 +482,10 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); ConceptSetComponent exclude = vs.getCompose().addExclude(); - exclude.setSystem(URL_MY_CODE_SYSTEM); + exclude.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); exclude.addConcept().setCode("childAA"); exclude.addConcept().setCode("childAAA"); @@ -500,7 +499,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { @Test public void testExpandWithIncludeContainingDashesInInclude() { CodeSystem codeSystem = new CodeSystem(); - codeSystem.setUrl(URL_MY_CODE_SYSTEM); + codeSystem.setUrl(TermTestUtil.URL_MY_CODE_SYSTEM); codeSystem.setVersion("SYSTEM VERSION"); codeSystem.setContent(CodeSystemContentMode.NOTPRESENT); IIdType id = myCodeSystemDao.create(codeSystem, mySrd).getId().toUnqualified(); @@ -526,10 +525,10 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { concept = new TermConcept(cs, "LA9999-7"); cs.getConcepts().add(concept); - myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); + myTermCodeSystemStorageSvc.storeNewCodeSystemVersion(new ResourcePersistentId(table.getId()), TermTestUtil.URL_MY_CODE_SYSTEM, "SYSTEM NAME", "SYSTEM VERSION", cs, table); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose() .addInclude() .setSystem(codeSystem.getUrl()) @@ -554,7 +553,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); /* * No system set on exclude @@ -576,7 +575,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setOp(FilterOperator.ISA).setValue("childAA").setProperty("concept"); ValueSet result = myValueSetDao.expand(vs, null); @@ -602,7 +601,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setOp(FilterOperator.ISA).setValue("childAA").setProperty("concept"); ValueSet result = myValueSetDao.expand(vs, null); @@ -620,7 +619,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addConcept().setCode("ZZZZ"); try { @@ -649,7 +648,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addConcept().setCode("AAA"); include.addFilter().setProperty("display").setOp(FilterOperator.EQUAL).setValue("AAA"); @@ -669,14 +668,14 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { int idx = codes.indexOf("AAA"); assertEquals("AAA", result.getExpansion().getContains().get(idx).getCode()); assertEquals("Code AAA", result.getExpansion().getContains().get(idx).getDisplay()); - assertEquals(URL_MY_CODE_SYSTEM, result.getExpansion().getContains().get(idx).getSystem()); + assertEquals(TermTestUtil.URL_MY_CODE_SYSTEM, result.getExpansion().getContains().get(idx).getSystem()); } // Now with a disjunction { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addConcept().setCode("A"); include.addFilter().setProperty("display").setOp(FilterOperator.EQUAL).setValue("AAA"); @@ -702,7 +701,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addConcept().setCode("ParentA"); include.addConcept().setCode("childAA"); include.addConcept().setCode("childAAA"); @@ -716,7 +715,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { int idx = codes.indexOf("childAA"); assertEquals("childAA", result.getExpansion().getContains().get(idx).getCode()); assertEquals("Child AA", result.getExpansion().getContains().get(idx).getDisplay()); - assertEquals(URL_MY_CODE_SYSTEM, result.getExpansion().getContains().get(idx).getSystem()); + assertEquals(TermTestUtil.URL_MY_CODE_SYSTEM, result.getExpansion().getContains().get(idx).getSystem()); } @Test @@ -725,7 +724,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addConcept().setCode("A"); include.addConcept().setCode("AA"); include.addConcept().setCode("AAA"); @@ -740,7 +739,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { int idx = codes.indexOf("AAA"); assertEquals("AAA", result.getExpansion().getContains().get(idx).getCode()); assertEquals("Code AAA", result.getExpansion().getContains().get(idx).getDisplay()); - assertEquals(URL_MY_CODE_SYSTEM, result.getExpansion().getContains().get(idx).getSystem()); + assertEquals(TermTestUtil.URL_MY_CODE_SYSTEM, result.getExpansion().getContains().get(idx).getSystem()); // ValueSet expansion = myValueSetDao.expandByIdentifier(URL_MY_VALUE_SET, "cervical"); // ValueSet expansion = myValueSetDao.expandByIdentifier(URL_MY_VALUE_SET, "cervical"); // @@ -751,7 +750,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { CodeSystem codeSystem = createExternalCsDogs(); ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); valueSet.getCompose() .addInclude() .setSystem(codeSystem.getUrl()); @@ -771,7 +770,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setProperty("display").setOp(FilterOperator.EQUAL).setValue("Parent B"); @@ -793,7 +792,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setProperty("concept").setOp(FilterOperator.ISA).setValue("ParentA"); ValueSet result = myValueSetDao.expand(vs, null); @@ -812,7 +811,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { vs = new ValueSet(); include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addFilter().setProperty("concept").setOp(FilterOperator.ISA).setValue("ParentA"); result = myValueSetDao.expand(vs, null); logAndValidateValueSet(result); @@ -870,7 +869,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { myDaoConfig.setMaximumExpansionSize(1); SearchParameterMap params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "AAA").setModifier(TokenParamModifier.ABOVE)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "AAA").setModifier(TokenParamModifier.ABOVE)); try { myObservationDao.search(params).size(); fail(); @@ -885,7 +884,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ValueSet vs = new ValueSet(); ConceptSetComponent include = vs.getCompose().addInclude(); - include.setSystem(URL_MY_CODE_SYSTEM); + include.setSystem(TermTestUtil.URL_MY_CODE_SYSTEM); include.addConcept().setCode("ZZZZ"); myResourceReindexingSvc.markAllResourcesForReindexing(); @@ -908,23 +907,23 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { createLocalCsAndVs(); Observation obsAA = new Observation(); - obsAA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("AA"); + obsAA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("AA"); IIdType idAA = myObservationDao.create(obsAA, mySrd).getId().toUnqualifiedVersionless(); Observation obsBA = new Observation(); - obsBA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("BA"); + obsBA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("BA"); myObservationDao.create(obsBA, mySrd).getId().toUnqualifiedVersionless(); Observation obsCA = new Observation(); - obsCA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("CA"); + obsCA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("CA"); myObservationDao.create(obsCA, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "AAA").setModifier(TokenParamModifier.ABOVE)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "AAA").setModifier(TokenParamModifier.ABOVE)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idAA.getValue())); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "A").setModifier(TokenParamModifier.ABOVE)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "A").setModifier(TokenParamModifier.ABOVE)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); } @@ -934,10 +933,10 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { SearchParameterMap params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.BELOW)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.BELOW)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.ABOVE)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.ABOVE)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); } @@ -1035,27 +1034,27 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { createExternalCsLarge(); Observation obs0 = new Observation(); - obs0.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("codeA"); + obs0.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("codeA"); IIdType id0 = myObservationDao.create(obs0, mySrd).getId().toUnqualifiedVersionless(); Observation obs1 = new Observation(); - obs1.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("subCodeA1"); + obs1.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("subCodeA1"); IIdType id1 = myObservationDao.create(obs1, mySrd).getId().toUnqualifiedVersionless(); Observation obs2 = new Observation(); - obs2.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("subCodeA2"); + obs2.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("subCodeA2"); IIdType id2 = myObservationDao.create(obs2, mySrd).getId().toUnqualifiedVersionless(); Observation obs3 = new Observation(); - obs3.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("subCodeB3"); + obs3.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("subCodeB3"); myObservationDao.create(obs3, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "codeA").setModifier(TokenParamModifier.BELOW)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "codeA").setModifier(TokenParamModifier.BELOW)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(id0.getValue(), id1.getValue(), id2.getValue())); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "subCodeB1").setModifier(TokenParamModifier.BELOW)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "subCodeB1").setModifier(TokenParamModifier.BELOW)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); } @@ -1065,23 +1064,23 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { createLocalCsAndVs(); Observation obsAA = new Observation(); - obsAA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("AA"); + obsAA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("AA"); IIdType idAA = myObservationDao.create(obsAA, mySrd).getId().toUnqualifiedVersionless(); Observation obsBA = new Observation(); - obsBA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("BA"); + obsBA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("BA"); myObservationDao.create(obsBA, mySrd).getId().toUnqualifiedVersionless(); Observation obsCA = new Observation(); - obsCA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("CA"); + obsCA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("CA"); myObservationDao.create(obsCA, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "A").setModifier(TokenParamModifier.BELOW)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "A").setModifier(TokenParamModifier.BELOW)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idAA.getValue())); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "AAA").setModifier(TokenParamModifier.BELOW)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "AAA").setModifier(TokenParamModifier.BELOW)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); } @@ -1124,7 +1123,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { @Test public void testSearchCodeInEmptyValueSet() { ValueSet valueSet = new ValueSet(); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); myValueSetDao.create(valueSet, mySrd); SearchParameterMap params; @@ -1132,13 +1131,13 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ourLog.info("testSearchCodeInEmptyValueSet without status"); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); ourLog.info("testSearchCodeInEmptyValueSet with status"); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); params.add(Observation.SP_STATUS, new TokenParam(null, "final")); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); @@ -1150,31 +1149,31 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { createExternalCsAndLocalVs(); Observation obsPA = new Observation(); - obsPA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("ParentA"); + obsPA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("ParentA"); IIdType idPA = myObservationDao.create(obsPA, mySrd).getId().toUnqualifiedVersionless(); Observation obsAAA = new Observation(); - obsAAA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("childAAA"); + obsAAA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("childAAA"); IIdType idAAA = myObservationDao.create(obsAAA, mySrd).getId().toUnqualifiedVersionless(); Observation obsAAB = new Observation(); - obsAAB.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("childAAB"); + obsAAB.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("childAAB"); IIdType idAAB = myObservationDao.create(obsAAB, mySrd).getId().toUnqualifiedVersionless(); Observation obsCA = new Observation(); - obsCA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("CA"); + obsCA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("CA"); myObservationDao.create(obsCA, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.BELOW)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.BELOW)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idAAA.getValue(), idAAB.getValue())); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.ABOVE)); + params.add(Observation.SP_CODE, new TokenParam(TermTestUtil.URL_MY_CODE_SYSTEM, "childAA").setModifier(TokenParamModifier.ABOVE)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idPA.getValue())); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idPA.getValue(), idAAA.getValue(), idAAB.getValue())); } @@ -1213,19 +1212,19 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { createLocalCsAndVs(); Observation obsAA = new Observation(); - obsAA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("AA"); + obsAA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("AA"); IIdType idAA = myObservationDao.create(obsAA, mySrd).getId().toUnqualifiedVersionless(); Observation obsBA = new Observation(); - obsBA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("BA"); + obsBA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("BA"); IIdType idBA = myObservationDao.create(obsBA, mySrd).getId().toUnqualifiedVersionless(); Observation obsCA = new Observation(); - obsCA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("CA"); + obsCA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("CA"); myObservationDao.create(obsCA, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params = SearchParameterMap.newSynchronous(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idAA.getValue(), idBA.getValue())); myCaptureQueriesListener.clear(); @@ -1239,19 +1238,19 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { createLocalCsAndVs(); Observation obsAA = new Observation(); - obsAA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("AA"); + obsAA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("AA"); IIdType idAA = myObservationDao.create(obsAA, mySrd).getId().toUnqualifiedVersionless(); Observation obsBA = new Observation(); - obsBA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("BA"); + obsBA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("BA"); IIdType idBA = myObservationDao.create(obsBA, mySrd).getId().toUnqualifiedVersionless(); Observation obsCA = new Observation(); - obsCA.getCode().addCoding().setSystem(URL_MY_CODE_SYSTEM).setCode("CA"); + obsCA.getCode().addCoding().setSystem(TermTestUtil.URL_MY_CODE_SYSTEM).setCode("CA"); IIdType idCA = myObservationDao.create(obsCA, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params = SearchParameterMap.newSynchronous(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.NOT_IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.NOT_IN)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), containsInAnyOrder(idCA.getValue())); myCaptureQueriesListener.clear(); @@ -1265,7 +1264,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { SearchParameterMap params = new SearchParameterMap(); try { - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); assertThat(toUnqualifiedVersionlessIdValues(myObservationDao.search(params)), empty()); } catch (ResourceNotFoundException e) { //noinspection SpellCheckingInspection @@ -1277,7 +1276,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { public void testSearchCodeInValueSetThatImportsInvalidCodeSystem() { ValueSet valueSet = new ValueSet(); valueSet.getCompose().addInclude().addValueSet("http://non_existant_VS"); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); IIdType vsId = myValueSetDao.create(valueSet, mySrd).getId().toUnqualifiedVersionless(); SearchParameterMap params; @@ -1285,7 +1284,7 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { ourLog.info("testSearchCodeInEmptyValueSet without status"); params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); try { myObservationDao.search(params); } catch (InvalidRequestException e) { @@ -1296,12 +1295,12 @@ public class FhirResourceDaoR4TerminologyTest extends BaseJpaR4Test { valueSet = new ValueSet(); valueSet.setId(vsId); valueSet.getCompose().addInclude().setSystem("http://terminology.hl7.org/CodeSystem/v3-MaritalStatus").addConcept().setCode("A"); - valueSet.setUrl(URL_MY_VALUE_SET); + valueSet.setUrl(TermTestUtil.URL_MY_VALUE_SET); myValueSetDao.update(valueSet, mySrd).getId().toUnqualifiedVersionless(); try { params = new SearchParameterMap(); - params.add(Observation.SP_CODE, new TokenParam(null, URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); + params.add(Observation.SP_CODE, new TokenParam(null, TermTestUtil.URL_MY_VALUE_SET).setModifier(TokenParamModifier.IN)); params.add(Observation.SP_STATUS, new TokenParam(null, "final")); } catch (ResourceNotFoundException e) { //noinspection SpellCheckingInspection diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTagSnapshotTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTagSnapshotTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTagSnapshotTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTagSnapshotTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4UpdateTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValidateTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValidateTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValidateTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValidateTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java index 469df94da69..2bc3ae509b8 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetMultiVersionTest.java @@ -6,6 +6,7 @@ import ca.uhn.fhir.jpa.entity.TermValueSet; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.util.ValueSetTestUtil; +import org.hamcrest.MatcherAssert; import org.hamcrest.Matchers; import org.hl7.fhir.r4.model.CodeSystem; import org.hl7.fhir.r4.model.ValueSet; @@ -19,7 +20,6 @@ import java.util.Map; import java.util.Optional; import java.util.Set; -import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; @@ -247,7 +247,7 @@ public class FhirResourceDaoR4ValueSetMultiVersionTest extends BaseJpaR4Test { include.addConcept().setCode("A"); ValueSet expansion = myValueSetDao.expand(vs, null); - assertThat(ValueSetTestUtil.toCodes(expansion), Matchers.contains("A")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), Matchers.contains("A")); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4ValueSetTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4VersionedReferenceTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4VersionedReferenceTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4VersionedReferenceTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoR4VersionedReferenceTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchListTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchListTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchListTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchListTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchParameterR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchParameterR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchParameterR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirResourceDaoSearchParameterR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSearchDaoR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSearchDaoR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSearchDaoR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSearchDaoR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java index 65b19bb83fe..77c39e1f5cd 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4SearchTest.java @@ -1,10 +1,7 @@ package ca.uhn.fhir.jpa.dao.r4; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; -import ca.uhn.fhir.util.TestUtil; - public class FhirSystemDaoR4SearchTest extends BaseJpaR4SystemTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java index d3b93e33dfa..a32b651dadf 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/FhirSystemDaoR4Test.java @@ -11,7 +11,7 @@ import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamString; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.model.entity.ResourceTag; import ca.uhn.fhir.jpa.model.entity.TagTypeEnum; -import ca.uhn.fhir.jpa.provider.SystemProviderDstu2Test; +import ca.uhn.fhir.jpa.provider.r4.SystemProviderR4Test; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.model.api.ResourceMetadataKeyEnum; import ca.uhn.fhir.model.primitive.IdDt; @@ -120,7 +120,6 @@ import static org.junit.jupiter.api.Assertions.assertNull; import static org.junit.jupiter.api.Assertions.assertThrows; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; -import static org.mockito.ArgumentMatchers.any; import static org.mockito.Mockito.when; public class FhirSystemDaoR4Test extends BaseJpaR4SystemTest { @@ -2726,7 +2725,7 @@ public class FhirSystemDaoR4Test extends BaseJpaR4SystemTest { @Test public void testTransactionFromBundle() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/transaction_link_patient_eve.xml"); + InputStream bundleRes = SystemProviderR4Test.class.getResourceAsStream("/transaction_link_patient_eve.xml"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle bundle = myFhirContext.newXmlParser().parseResource(Bundle.class, bundleStr); @@ -2767,7 +2766,7 @@ public class FhirSystemDaoR4Test extends BaseJpaR4SystemTest { @Test public void testTransactionFromBundle6() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/simone_bundle3.xml"); + InputStream bundleRes = SystemProviderR4Test.class.getResourceAsStream("/simone_bundle3.xml"); String bundle = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle output = mySystemDao.transaction(mySrd, myFhirContext.newXmlParser().parseResource(Bundle.class, bundle)); ourLog.info(myFhirContext.newXmlParser().setPrettyPrint(true).encodeResourceToString(output)); @@ -2776,7 +2775,7 @@ public class FhirSystemDaoR4Test extends BaseJpaR4SystemTest { @Test public void testTransactionFromBundleJosh() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/josh-bundle.json"); + InputStream bundleRes = SystemProviderR4Test.class.getResourceAsStream("/josh-bundle.json"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle bundle = myFhirContext.newJsonParser().parseResource(Bundle.class, bundleStr); @@ -3466,7 +3465,7 @@ public class FhirSystemDaoR4Test extends BaseJpaR4SystemTest { @Disabled public void testTransactionWithBundledValidationSourceAndTarget() throws Exception { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/questionnaire-sdc-profile-example-ussg-fht.xml"); + InputStream bundleRes = SystemProviderR4Test.class.getResourceAsStream("/questionnaire-sdc-profile-example-ussg-fht.xml"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); Bundle bundle = myFhirContext.newXmlParser().parseResource(Bundle.class, bundleStr); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/JpaHistoryR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/JpaHistoryR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/JpaHistoryR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/JpaHistoryR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java index 55c754a475f..3e4c4bde47c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningNonNullDefaultPartitionR4Test.java @@ -17,7 +17,6 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import javax.servlet.ServletException; - import java.util.List; import static org.hamcrest.MatcherAssert.assertThat; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java index ddcf88fc471..af06a11ab14 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSearchCacheR4Test.java @@ -11,7 +11,6 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import java.util.List; -import java.util.stream.Collectors; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsInAnyOrder; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSqlR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSqlR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSqlR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/PartitioningSqlR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java index fefe2fb02d0..6bace33d115 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchCoordinatorSvcImplTest.java @@ -20,9 +20,7 @@ import java.util.Date; import java.util.UUID; import static ca.uhn.fhir.jpa.search.cache.DatabaseSearchCacheSvcImpl.DEFAULT_MAX_DELETE_CANDIDATES_TO_FIND; -import static org.hamcrest.Matchers.containsInAnyOrder; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.hamcrest.MatcherAssert.assertThat; public class SearchCoordinatorSvcImplTest extends BaseJpaR4Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParamExtractorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParamExtractorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParamExtractorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParamExtractorR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java index b51ee25cc1a..dd4c37a27ee 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchParameterMapTest.java @@ -15,8 +15,6 @@ import ca.uhn.fhir.test.BaseTest; import org.junit.jupiter.api.Test; import org.slf4j.Logger; -import java.util.Date; - import static org.junit.jupiter.api.Assertions.assertEquals; import static org.slf4j.LoggerFactory.getLogger; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchWithInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchWithInterceptorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchWithInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SearchWithInterceptorR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SyntheaPerfTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SyntheaPerfTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/SyntheaPerfTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/SyntheaPerfTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TestContextLoads.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TestContextLoads.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TestContextLoads.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TestContextLoads.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java index 9b09227e9d7..e16dc9a8850 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionDeleteR4Test.java @@ -11,9 +11,9 @@ import org.hl7.fhir.r4.model.Reference; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Test; +import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.empty; import static org.hamcrest.Matchers.matchesPattern; -import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.fail; public class TransactionDeleteR4Test extends BaseJpaR4SystemTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionHookTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionHookTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionHookTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/dao/r4/TransactionHookTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/DeleteConflictServiceR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/DeleteConflictServiceR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/DeleteConflictServiceR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/DeleteConflictServiceR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/job/DeleteExpungeJobTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/job/DeleteExpungeJobTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/job/DeleteExpungeJobTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/job/DeleteExpungeJobTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexJobTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexJobTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexJobTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexJobTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexTestHelper.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexTestHelper.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexTestHelper.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/delete/job/ReindexTestHelper.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java similarity index 95% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java index c080bea3674..0f529e87781 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/graphql/DaoRegistryGraphQLStorageServicesTest.java @@ -1,10 +1,9 @@ package ca.uhn.fhir.jpa.graphql; -import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.config.TestR4Config; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; +import ca.uhn.fhir.jpa.test.config.TestR4Config; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.util.BundleUtil; import org.apache.http.NameValuePair; @@ -22,8 +21,6 @@ import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.annotation.DirtiesContext; import org.springframework.test.context.ContextConfiguration; @@ -32,12 +29,20 @@ import org.springframework.test.context.junit.jupiter.SpringExtension; import java.net.URI; import java.net.URISyntaxException; import java.nio.charset.StandardCharsets; -import java.util.*; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Optional; import static ca.uhn.fhir.jpa.graphql.DaoRegistryGraphQLStorageServices.SEARCH_ID_PARAM; import static ca.uhn.fhir.jpa.graphql.DaoRegistryGraphQLStorageServices.SEARCH_OFFSET_PARAM; -import static org.junit.jupiter.api.Assertions.*; - +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertFalse; +import static org.junit.jupiter.api.Assertions.assertTrue; +import static org.junit.jupiter.api.Assertions.fail; import static org.mockito.Mockito.when; @ContextConfiguration(classes = {TestR4Config.class}) diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/CascadingDeleteInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/CascadingDeleteInterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/CascadingDeleteInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/CascadingDeleteInterceptorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ForceOffsetSearchModeInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/ForceOffsetSearchModeInterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ForceOffsetSearchModeInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/ForceOffsetSearchModeInterceptorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java index cd7ed07ab34..316622377d1 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/OverridePathBasedReferentialIntegrityForDeletesInterceptorTest.java @@ -1,7 +1,7 @@ package ca.uhn.fhir.jpa.interceptor; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.rest.param.ReferenceParam; import ca.uhn.fhir.rest.server.exceptions.ResourceGoneException; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java index c7913ea176a..27d97678478 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/PartitioningInterceptorR4Test.java @@ -16,7 +16,6 @@ import ca.uhn.fhir.jpa.interceptor.ex.PartitionInterceptorReadPartitionsBasedOnS import ca.uhn.fhir.jpa.model.config.PartitionSettings; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.partition.IPartitionLookupSvc; -import ca.uhn.fhir.jpa.partition.SystemRequestDetails; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.rest.api.RestOperationTypeEnum; import ca.uhn.fhir.rest.api.server.IBundleProvider; @@ -24,7 +23,6 @@ import ca.uhn.fhir.rest.api.server.RequestDetails; import ca.uhn.fhir.rest.server.exceptions.InternalErrorException; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; import ca.uhn.fhir.rest.server.servlet.ServletRequestDetails; -import ca.uhn.fhir.util.ExtensionUtil; import ca.uhn.fhir.util.HapiExtensions; import com.google.common.collect.Sets; import org.apache.commons.lang3.StringUtils; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/PatientIdPartitionInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/PatientIdPartitionInterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/PatientIdPartitionInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/PatientIdPartitionInterceptorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ResponseTerminologyTranslationInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/ResponseTerminologyTranslationInterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ResponseTerminologyTranslationInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/ResponseTerminologyTranslationInterceptorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java similarity index 93% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java index 247286c21f6..978a56c7dd0 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/SearchPreferHandlingInterceptorJpaTest.java @@ -1,27 +1,16 @@ package ca.uhn.fhir.jpa.interceptor; import ca.uhn.fhir.jpa.provider.r4.BaseResourceProviderR4Test; -import ca.uhn.fhir.model.api.ResourceMetadataKeyEnum; -import ca.uhn.fhir.model.valueset.BundleEntrySearchModeEnum; -import ca.uhn.fhir.rest.annotation.OptionalParam; -import ca.uhn.fhir.rest.annotation.Search; import ca.uhn.fhir.rest.api.Constants; import ca.uhn.fhir.rest.gclient.StringClientParam; -import ca.uhn.fhir.rest.param.TokenAndListParam; -import ca.uhn.fhir.rest.server.IResourceProvider; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.interceptor.SearchPreferHandlingInterceptor; -import org.hl7.fhir.instance.model.api.IBaseResource; import org.hl7.fhir.r4.model.Bundle; -import org.hl7.fhir.r4.model.HumanName; import org.hl7.fhir.r4.model.Patient; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; -import java.util.ArrayList; -import java.util.List; - import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java index c93f7e6368f..21af4da75d7 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorHttpR4Test.java @@ -1,8 +1,8 @@ package ca.uhn.fhir.jpa.interceptor.validation; import ca.uhn.fhir.context.FhirVersionEnum; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.rp.r4.ObservationResourceProvider; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.MethodOutcome; import ca.uhn.fhir.rest.api.PreferReturnEnum; import ca.uhn.fhir.rest.server.interceptor.ValidationResultEnrichingInterceptor; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/RepositoryValidatingInterceptorR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/ValidationMessageSuppressingInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/ValidationMessageSuppressingInterceptorTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/ValidationMessageSuppressingInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/interceptor/validation/ValidationMessageSuppressingInterceptorTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java index a6c9a0f8d92..fda19f52625 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/JpaPackageCacheTest.java @@ -4,10 +4,10 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.interceptor.api.IInterceptorService; import ca.uhn.fhir.jpa.dao.data.INpmPackageDao; import ca.uhn.fhir.jpa.dao.data.INpmPackageVersionDao; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.interceptor.PatientIdPartitionInterceptor; import ca.uhn.fhir.jpa.model.config.PartitionSettings; import ca.uhn.fhir.jpa.searchparam.extractor.ISearchParamExtractor; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; import ca.uhn.fhir.rest.server.interceptor.partition.RequestTenantPartitionInterceptor; @@ -161,7 +161,7 @@ public class JpaPackageCacheTest extends BaseJpaR4Test { public void testPackageIdHandlingIsNotCaseSensitive() { String packageNameAllLowercase = "hl7.fhir.us.davinci-cdex"; String packageNameUppercase = packageNameAllLowercase.toUpperCase(Locale.ROOT); - InputStream stream = IgInstallerDstu3Test.class.getResourceAsStream("/packages/package-davinci-cdex-0.2.0.tgz"); + InputStream stream = JpaPackageCacheTest.class.getResourceAsStream("/packages/package-davinci-cdex-0.2.0.tgz"); // The package has the ID in lower-case, so for the test we input the first parameter in upper-case & check that no error is thrown assertDoesNotThrow(() -> myPackageCacheManager.addPackageToCache(packageNameUppercase, "0.2.0", stream, "hl7.fhir.us.davinci-cdex")); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java similarity index 91% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java index ed5428c6818..b0a1c5b5984 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/NpmR4Test.java @@ -9,15 +9,14 @@ import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; import ca.uhn.fhir.jpa.dao.data.INpmPackageDao; import ca.uhn.fhir.jpa.dao.data.INpmPackageVersionDao; import ca.uhn.fhir.jpa.dao.data.INpmPackageVersionResourceDao; -import ca.uhn.fhir.jpa.partition.SystemRequestDetails; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.model.config.PartitionSettings; import ca.uhn.fhir.jpa.model.entity.NpmPackageEntity; import ca.uhn.fhir.jpa.model.entity.NpmPackageVersionEntity; import ca.uhn.fhir.jpa.model.entity.NpmPackageVersionResourceEntity; import ca.uhn.fhir.jpa.model.util.JpaConstants; +import ca.uhn.fhir.jpa.partition.SystemRequestDetails; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; -import ca.uhn.fhir.rest.api.Constants; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.rest.param.ReferenceParam; import ca.uhn.fhir.rest.param.TokenParam; @@ -29,7 +28,6 @@ import ca.uhn.fhir.test.utilities.JettyUtil; import ca.uhn.fhir.test.utilities.ProxyUtil; import ca.uhn.fhir.util.ClasspathUtil; import ca.uhn.fhir.util.JsonUtil; -import org.apache.commons.lang3.StringUtils; import org.eclipse.jetty.server.Server; import org.eclipse.jetty.servlet.ServletHandler; import org.eclipse.jetty.servlet.ServletHolder; @@ -56,16 +54,11 @@ import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Slice; -import javax.servlet.http.HttpServlet; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.nio.file.Path; import java.nio.file.Paths; import java.util.ArrayList; -import java.util.HashMap; import java.util.List; -import java.util.Map; import java.util.stream.Collectors; import static org.hamcrest.MatcherAssert.assertThat; @@ -122,7 +115,7 @@ public class NpmR4Test extends BaseJpaR4Test { jpaPackageCache.getPackageServers().clear(); jpaPackageCache.addPackageServer("http://localhost:" + port); - myFakeNpmServlet.myResponses.clear(); + myFakeNpmServlet.responses.clear(); } @AfterEach @@ -170,7 +163,7 @@ public class NpmR4Test extends BaseJpaR4Test { @Test public void testCacheDstu3Package() throws Exception { byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/nictiz.fhir.nl.stu3.questionnaires-1.0.2.tgz"); - myFakeNpmServlet.myResponses.put("/nictiz.fhir.nl.stu3.questionnaires/1.0.2", bytes); + myFakeNpmServlet.responses.put("/nictiz.fhir.nl.stu3.questionnaires/1.0.2", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("nictiz.fhir.nl.stu3.questionnaires").setVersion("1.0.2").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY); myPackageInstallerSvc.install(spec); @@ -209,7 +202,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); PackageInstallOutcomeJson outcome = myPackageInstallerSvc.install(spec); @@ -279,7 +272,7 @@ public class NpmR4Test extends BaseJpaR4Test { myInterceptorService.registerInterceptor(myBinaryStorageInterceptor); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); PackageInstallOutcomeJson outcome = myPackageInstallerSvc.install(spec); @@ -351,7 +344,7 @@ public class NpmR4Test extends BaseJpaR4Test { // Load a copy of hl7.fhir.uv.shorthand-0.12.0, but with id set to 1 instead of "shorthand-code-system" byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.13.0.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.13.0", bytes); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.13.0", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.13.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); PackageInstallOutcomeJson outcome = myPackageInstallerSvc.install(spec); @@ -375,7 +368,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-organizations-package.tgz"); - myFakeNpmServlet.myResponses.put("/test-organizations/1.0.0", bytes); + myFakeNpmServlet.responses.put("/test-organizations/1.0.0", bytes); List resourceList = new ArrayList<>(); resourceList.add("Organization"); @@ -412,7 +405,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-organizations-package.tgz"); - myFakeNpmServlet.myResponses.put("/test-organizations/1.0.0", bytes); + myFakeNpmServlet.responses.put("/test-organizations/1.0.0", bytes); List resourceList = new ArrayList<>(); resourceList.add("Organization"); @@ -451,7 +444,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-missing-identifier-package.tgz"); - myFakeNpmServlet.myResponses.put("/test-missing-identifier-package/1.0.0", bytes); + myFakeNpmServlet.responses.put("/test-missing-identifier-package/1.0.0", bytes); List resourceList = new ArrayList<>(); resourceList.add("Organization"); @@ -474,7 +467,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAutoCreatePlaceholderReferenceTargets(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-auto-create-placeholder.tgz"); - myFakeNpmServlet.myResponses.put("/test-ig/1.0.0", bytes); + myFakeNpmServlet.responses.put("/test-ig/1.0.0", bytes); List resourceList = new ArrayList<>(); resourceList.add("ImplementationGuide"); @@ -501,7 +494,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-draft-sample.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.onlydrafts/0.11.1", bytes); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.onlydrafts/0.11.1", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.onlydrafts").setVersion("0.11.1").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); PackageInstallOutcomeJson outcome = myPackageInstallerSvc.install(spec); @@ -514,7 +507,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); PackageInstallOutcomeJson outcome; @@ -539,7 +532,7 @@ public class NpmR4Test extends BaseJpaR4Test { myInterceptorService.registerInterceptor(myRequestTenantPartitionInterceptor); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", bytes); PackageInstallOutcomeJson outcome; @@ -563,7 +556,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/UK.Core.r4-1.1.0.tgz"); - myFakeNpmServlet.myResponses.put("/UK.Core.r4/1.1.0", bytes); + myFakeNpmServlet.responses.put("/UK.Core.r4/1.1.0", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("UK.Core.r4").setVersion("1.1.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); myPackageInstallerSvc.install(spec); @@ -582,8 +575,8 @@ public class NpmR4Test extends BaseJpaR4Test { public void testLoadPackageMetadata() throws Exception { myDaoConfig.setAllowExternalReferences(true); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY); myPackageInstallerSvc.install(spec); @@ -609,9 +602,9 @@ public class NpmR4Test extends BaseJpaR4Test { public void testLoadPackageUsingImpreciseId() throws Exception { myDaoConfig.setAllowExternalReferences(true); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.0.tgz")); PackageInstallationSpec spec; spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY); @@ -645,8 +638,8 @@ public class NpmR4Test extends BaseJpaR4Test { byte[] contents0111 = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz"); byte[] contents0120 = ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz"); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.1", contents0111); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", contents0120); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.1", contents0111); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", contents0120); // Install older version PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.11.1").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY); @@ -688,8 +681,8 @@ public class NpmR4Test extends BaseJpaR4Test { public void testInstallOlderPackageDoesntUpdateLatestVersionFlag() throws Exception { myDaoConfig.setAllowExternalReferences(true); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); // Install newer version PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY); @@ -731,7 +724,7 @@ public class NpmR4Test extends BaseJpaR4Test { public void testInstallAlreadyExistingIsIgnored() throws Exception { myDaoConfig.setAllowExternalReferences(true); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); // Install PackageInstallationSpec spec = new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY); @@ -757,10 +750,10 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] contents0111 = ClasspathUtil.loadResourceAsByteArray("/packages/test-exchange-sample.tgz"); - myFakeNpmServlet.myResponses.put("/test-exchange.fhir.us.com/2.1.1", contents0111); + myFakeNpmServlet.responses.put("/test-exchange.fhir.us.com/2.1.1", contents0111); contents0111 = ClasspathUtil.loadResourceAsByteArray("/packages/test-exchange-sample-2.tgz"); - myFakeNpmServlet.myResponses.put("/test-exchange.fhir.us.com/2.1.2", contents0111); + myFakeNpmServlet.responses.put("/test-exchange.fhir.us.com/2.1.2", contents0111); // Install older version PackageInstallationSpec spec = new PackageInstallationSpec().setName("test-exchange.fhir.us.com").setVersion("2.1.1").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); @@ -826,9 +819,9 @@ public class NpmR4Test extends BaseJpaR4Test { public void testDeletePackage() throws IOException { myDaoConfig.setAllowExternalReferences(true); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); - myFakeNpmServlet.myResponses.put("/hl7.fhir.uv.shorthand/0.11.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.12.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.12.0.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.1", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.1.tgz")); + myFakeNpmServlet.responses.put("/hl7.fhir.uv.shorthand/0.11.0", ClasspathUtil.loadResourceAsByteArray("/packages/hl7.fhir.uv.shorthand-0.11.0.tgz")); myPackageInstallerSvc.install(new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.12.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY)); myPackageInstallerSvc.install(new PackageInstallationSpec().setName("hl7.fhir.uv.shorthand").setVersion("0.11.1").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_ONLY)); @@ -872,7 +865,7 @@ public class NpmR4Test extends BaseJpaR4Test { myDaoConfig.setAllowExternalReferences(true); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-logical-structuredefinition.tgz"); - myFakeNpmServlet.myResponses.put("/test-logical-structuredefinition/1.0.0", bytes); + myFakeNpmServlet.responses.put("/test-logical-structuredefinition/1.0.0", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("test-logical-structuredefinition").setVersion("1.0.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); PackageInstallOutcomeJson outcome = myPackageInstallerSvc.install(spec); @@ -909,7 +902,7 @@ public class NpmR4Test extends BaseJpaR4Test { myInterceptorService.registerInterceptor(myRequestTenantPartitionInterceptor); byte[] bytes = ClasspathUtil.loadResourceAsByteArray("/packages/test-logical-structuredefinition.tgz"); - myFakeNpmServlet.myResponses.put("/test-logical-structuredefinition/1.0.0", bytes); + myFakeNpmServlet.responses.put("/test-logical-structuredefinition/1.0.0", bytes); PackageInstallationSpec spec = new PackageInstallationSpec().setName("test-logical-structuredefinition").setVersion("1.0.0").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL); PackageInstallOutcomeJson outcome = myPackageInstallerSvc.install(spec); @@ -958,35 +951,4 @@ public class NpmR4Test extends BaseJpaR4Test { }); } - static class FakeNpmServlet extends HttpServlet { - - private final Map myResponses = new HashMap<>(); - - @Override - protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException { - String requestUrl = req.getRequestURI(); - if (myResponses.containsKey(requestUrl)) { - ourLog.info("Responding to request: {}", requestUrl); - - resp.setStatus(200); - - if (StringUtils.countMatches(requestUrl, "/") == 1) { - resp.setHeader(Constants.HEADER_CONTENT_TYPE, Constants.CT_JSON); - }else { - resp.setHeader(Constants.HEADER_CONTENT_TYPE, "application/gzip"); - } - resp.getOutputStream().write(myResponses.get(requestUrl)); - resp.getOutputStream().close(); - } else { - ourLog.warn("Unknown request: {}", requestUrl); - - resp.sendError(404); - } - - } - - public Map getResponses() { - return myResponses; - } - } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmSearchR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/NpmSearchR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/NpmSearchR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/NpmSearchR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/packages/PackageInstallerSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java index fe301ec4e8d..a6b90f5d56a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionManagementProviderTest.java @@ -28,7 +28,6 @@ import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit.jupiter.SpringExtension; import javax.annotation.Nonnull; - import java.util.ArrayList; import java.util.List; import java.util.stream.Collectors; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java index bbf323ad08a..a1401da9004 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionSettingsSvcImplTest.java @@ -1,8 +1,8 @@ package ca.uhn.fhir.jpa.partition; import ca.uhn.fhir.i18n.Msg; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.entity.PartitionEntity; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.MethodNotAllowedException; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java similarity index 88% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java index eb025492cf8..cd40b728681 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/PartitionedSubscriptionTriggeringR4Test.java @@ -7,13 +7,13 @@ import ca.uhn.fhir.interceptor.model.RequestPartitionId; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; import ca.uhn.fhir.jpa.api.model.ExpungeOptions; -import ca.uhn.fhir.jpa.test.util.StoppableSubscriptionDeliveringRestHookSubscriber; import ca.uhn.fhir.jpa.dao.r4.BasePartitioningR4Test; import ca.uhn.fhir.jpa.entity.PartitionEntity; import ca.uhn.fhir.jpa.model.config.PartitionSettings; import ca.uhn.fhir.jpa.subscription.BaseSubscriptionsR4Test; import ca.uhn.fhir.jpa.subscription.resthook.RestHookTestR4Test; import ca.uhn.fhir.jpa.subscription.triggering.ISubscriptionTriggeringSvc; +import ca.uhn.fhir.jpa.test.util.StoppableSubscriptionDeliveringRestHookSubscriber; import ca.uhn.fhir.rest.api.Constants; import org.awaitility.core.ConditionTimeoutException; import org.hl7.fhir.instance.model.api.IPrimitiveType; @@ -22,6 +22,7 @@ import org.hl7.fhir.r4.model.Parameters; import org.hl7.fhir.r4.model.Patient; import org.hl7.fhir.r4.model.Subscription; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.slf4j.Logger; @@ -35,7 +36,6 @@ import java.util.ArrayList; import static org.hamcrest.CoreMatchers.containsString; import static org.hamcrest.MatcherAssert.assertThat; -import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4Test { @@ -109,7 +109,7 @@ public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4 String criteria1 = "Observation?code=SNOMED-CT|" + code + "&_format=xml"; Subscription subscription = newSubscription(criteria1, payload); - assertEquals(mySrdInterceptorService.getAllRegisteredInterceptors().size(), 1); + Assertions.assertEquals(mySrdInterceptorService.getAllRegisteredInterceptors().size(), 1); myDaoRegistry.getResourceDao("Subscription").create(subscription, mySrd); @@ -120,10 +120,10 @@ public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4 // Should see 1 subscription notification waitForQueueToDrain(); - assertEquals(0, ourObservationProvider.getCountCreate()); - ourObservationProvider.waitForUpdateCount(1); + Assertions.assertEquals(0, BaseSubscriptionsR4Test.ourObservationProvider.getCountCreate()); + BaseSubscriptionsR4Test.ourObservationProvider.waitForUpdateCount(1); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourRestfulServer.getRequestContentTypes().get(0)); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR4Test.ourRestfulServer.getRequestContentTypes().get(0)); } @Test @@ -134,7 +134,7 @@ public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4 String criteria1 = "Patient?active=true"; Subscription subscription = newSubscription(criteria1, payload); - assertEquals(mySrdInterceptorService.getAllRegisteredInterceptors().size(), 1); + Assertions.assertEquals(mySrdInterceptorService.getAllRegisteredInterceptors().size(), 1); myDaoRegistry.getResourceDao("Subscription").create(subscription, mySrd); @@ -146,14 +146,14 @@ public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4 // Should see 0 subscription notification waitForQueueToDrain(); - assertEquals(0, ourPatientProvider.getCountCreate()); + Assertions.assertEquals(0, BaseSubscriptionsR4Test.ourPatientProvider.getCountCreate()); try { // Should have 0 matching subscription, if we get 1 update count then the test fails - ourPatientProvider.waitForUpdateCount(1); + BaseSubscriptionsR4Test.ourPatientProvider.waitForUpdateCount(1); fail(); } catch (ConditionTimeoutException e) { - assertEquals(0, ourRestfulServer.getRequestContentTypes().size()); + Assertions.assertEquals(0, BaseSubscriptionsR4Test.ourRestfulServer.getRequestContentTypes().size()); } } @@ -171,7 +171,7 @@ public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4 // Create the subscription now DaoMethodOutcome subscriptionOutcome = myDaoRegistry.getResourceDao("Subscription").create(newSubscription(criteria1, payload), mySrd); - assertEquals(mySrdInterceptorService.getAllRegisteredInterceptors().size(), 1); + Assertions.assertEquals(mySrdInterceptorService.getAllRegisteredInterceptors().size(), 1); Subscription subscription = (Subscription) subscriptionOutcome.getResource(); @@ -184,7 +184,7 @@ public class PartitionedSubscriptionTriggeringR4Test extends BaseSubscriptionsR4 Parameters resultParameters = (Parameters) mySubscriptionTriggeringSvc.triggerSubscription(resourceIdList, null, subscription.getIdElement()); waitForQueueToDrain(); - assertEquals(0, ourObservationProvider.getCountCreate()); + Assertions.assertEquals(0, BaseSubscriptionsR4Test.ourObservationProvider.getCountCreate()); String responseValue = resultParameters.getParameter().get(0).getValue().primitiveValue(); assertThat(responseValue, containsString("Subscription triggering job submitted as JOB ID")); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/RequestPartitionHelperSvcTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/RequestPartitionHelperSvcTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/partition/RequestPartitionHelperSvcTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/partition/RequestPartitionHelperSvcTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchApplyR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchApplyR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchApplyR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchApplyR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchDiffR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchDiffR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchDiffR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/patch/FhirPatchDiffR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java similarity index 92% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java index bda7ff0e3d9..57239f69ea1 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/GraphQLR4ProviderTest.java @@ -44,8 +44,6 @@ import static org.junit.jupiter.api.Assertions.assertEquals; public class GraphQLR4ProviderTest { - public static final String DATA_PREFIX = "{\"data\": "; - public static final String DATA_SUFFIX = "}"; private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(GraphQLR4ProviderTest.class); private static final FhirContext ourCtx = FhirContext.forR4Cached(); private static CloseableHttpClient ourClient; @@ -70,14 +68,14 @@ public class GraphQLR4ProviderTest { ourLog.info(responseContent); assertEquals(200, status.getStatusLine().getStatusCode()); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX + "{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX + "{\n" + " \"name\":[{\n" + " \"family\":\"FAMILY\",\n" + " \"given\":[\"GIVEN1\",\"GIVEN2\"]\n" + " },{\n" + " \"given\":[\"GivenOnly1\",\"GivenOnly2\"]\n" + " }]\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); assertThat(status.getFirstHeader(Constants.HEADER_CONTENT_TYPE).getValue(), startsWith("application/json")); } @@ -92,12 +90,12 @@ public class GraphQLR4ProviderTest { ourLog.info(responseContent); assertEquals(200, status.getStatusLine().getStatusCode()); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX + "{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX + "{\n" + " \"name\":[{\n" + " \"given\":[\"GIVEN1\",\"GIVEN2\"],\n" + " \"family\":\"FAMILY\"\n" + " }]\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); assertThat(status.getFirstHeader(Constants.HEADER_CONTENT_TYPE).getValue(), startsWith("application/json")); } @@ -112,7 +110,7 @@ public class GraphQLR4ProviderTest { ourLog.info(responseContent); assertEquals(200, status.getStatusLine().getStatusCode()); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX + "{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX + "{\n" + " \"Patient\":{\n" + " \"name\":[{\n" + " \"given\":[\"GIVEN1\",\"GIVEN2\"],\n" + @@ -121,7 +119,7 @@ public class GraphQLR4ProviderTest { " \"given\":[\"GivenOnly1\",\"GivenOnly2\"]\n" + " }]\n" + " }\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); assertThat(status.getFirstHeader(Constants.HEADER_CONTENT_TYPE).getValue(), startsWith("application/json")); } @@ -137,7 +135,7 @@ public class GraphQLR4ProviderTest { ourLog.info(responseContent); assertEquals(200, status.getStatusLine().getStatusCode()); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX + "{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX + "{\n" + " \"PatientList\":[{\n" + " \"name\":[{\n" + " \"family\":\"pet\",\n" + @@ -150,7 +148,7 @@ public class GraphQLR4ProviderTest { " \"given\":[\"pet\",\"GivenOnlyB1\",\"GivenOnlyB2\"]\n" + " }]\n" + " }]\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); assertThat(status.getFirstHeader(Constants.HEADER_CONTENT_TYPE).getValue(), startsWith("application/json")); } @@ -166,7 +164,7 @@ public class GraphQLR4ProviderTest { ourLog.info(responseContent); assertEquals(200, status.getStatusLine().getStatusCode()); - assertEquals(TestUtil.stripWhitespace(DATA_PREFIX + "{\n" + + assertEquals(TestUtil.stripWhitespace(GraphQLProviderTestUtil.DATA_PREFIX + "{\n" + " \"PatientList\":[{\n" + " \"id\":\"Patient/hapi-123/_history/2\",\n" + " \"name\":[{\n" + @@ -178,7 +176,7 @@ public class GraphQLR4ProviderTest { " \"family\":\"FAMILY 124\"\n" + " }]\n" + " }]\n" + - "}" + DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); + "}" + GraphQLProviderTestUtil.DATA_SUFFIX), TestUtil.stripWhitespace(responseContent)); assertThat(status.getFirstHeader(Constants.HEADER_CONTENT_TYPE).getValue(), startsWith("application/json")); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/TerminologyUploaderProviderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/TerminologyUploaderProviderTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/TerminologyUploaderProviderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/TerminologyUploaderProviderTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java index bc7600f5eec..919b1f758d8 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorJpaR4Test.java @@ -2,11 +2,11 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.bulk.export.provider.BulkDataExportProvider; -import ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest; import ca.uhn.fhir.jpa.interceptor.CascadingDeleteInterceptor; import ca.uhn.fhir.jpa.model.util.JpaConstants; import ca.uhn.fhir.jpa.searchparam.matcher.AuthorizationSearchParamMatcher; import ca.uhn.fhir.jpa.searchparam.matcher.SearchParamMatcher; +import ca.uhn.fhir.jpa.term.TermTestUtil; import ca.uhn.fhir.model.primitive.IdDt; import ca.uhn.fhir.rest.api.Constants; import ca.uhn.fhir.rest.api.MethodOutcome; @@ -402,14 +402,14 @@ public class AuthorizationInterceptorJpaR4Test extends BaseResourceProviderR4Tes public void testSearchCodeIn() { createLocalCsAndVs(); - createObservation(withId("allowed"), withObservationCode(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM, "A")); - createObservation(withId("disallowed"), withObservationCode(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM, "foo")); + createObservation(withId("allowed"), withObservationCode(TermTestUtil.URL_MY_CODE_SYSTEM, "A")); + createObservation(withId("disallowed"), withObservationCode(TermTestUtil.URL_MY_CODE_SYSTEM, "foo")); ourRestServer.registerInterceptor(new AuthorizationInterceptor(PolicyEnum.DENY) { @Override public List buildRuleList(RequestDetails theRequestDetails) { return new RuleBuilder() - .allow().read().resourcesOfType("Observation").withCodeInValueSet("code", FhirResourceDaoR4TerminologyTest.URL_MY_VALUE_SET).andThen() + .allow().read().resourcesOfType("Observation").withCodeInValueSet("code", TermTestUtil.URL_MY_VALUE_SET).andThen() .build(); } }.setValidationSupport(myValidationSupport)); @@ -1457,15 +1457,15 @@ public class AuthorizationInterceptorJpaR4Test extends BaseResourceProviderR4Tes @Test public void testSmartFilterSearchAllowed() { - createObservation(withId("allowed"), withObservationCode(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM, "A")); - createObservation(withId("allowed2"), withObservationCode(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM, "foo")); + createObservation(withId("allowed"), withObservationCode(TermTestUtil.URL_MY_CODE_SYSTEM, "A")); + createObservation(withId("allowed2"), withObservationCode(TermTestUtil.URL_MY_CODE_SYSTEM, "foo")); AuthorizationInterceptor interceptor = new AuthorizationInterceptor(PolicyEnum.DENY) { @Override public List buildRuleList(RequestDetails theRequestDetails) { return new RuleBuilder() .allow("filter rule").read().allResources().withAnyId() - .withFilterTester("code=" + FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM + "|") + .withFilterTester("code=" + TermTestUtil.URL_MY_CODE_SYSTEM + "|") .andThen().build(); } }; @@ -1479,8 +1479,8 @@ public class AuthorizationInterceptorJpaR4Test extends BaseResourceProviderR4Tes @Test public void testSmartFilterSearch_badQuery_abstain() { - createObservation(withId("obs1"), withObservationCode(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM, "A")); - createObservation(withId("obs2"), withObservationCode(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM, "foo")); + createObservation(withId("obs1"), withObservationCode(TermTestUtil.URL_MY_CODE_SYSTEM, "A")); + createObservation(withId("obs2"), withObservationCode(TermTestUtil.URL_MY_CODE_SYSTEM, "foo")); AuthorizationInterceptor interceptor = new AuthorizationInterceptor(PolicyEnum.DENY) { @Override diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorMultitenantJpaR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorMultitenantJpaR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorMultitenantJpaR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/AuthorizationInterceptorMultitenantJpaR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BaseMultitenantResourceProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BaseMultitenantResourceProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BaseMultitenantResourceProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BaseMultitenantResourceProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryAccessProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryAccessProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryAccessProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryAccessProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java index ca83871efbe..64641524314 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/BinaryStorageInterceptorR4Test.java @@ -3,8 +3,8 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; -import ca.uhn.fhir.jpa.binary.interceptor.BinaryStorageInterceptor; import ca.uhn.fhir.jpa.binary.api.IBinaryStorageSvc; +import ca.uhn.fhir.jpa.binary.interceptor.BinaryStorageInterceptor; import ca.uhn.fhir.jpa.binstore.MemoryBinaryStorageSvcImpl; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.util.HapiExtensions; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/CompositionDocumentR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/CompositionDocumentR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/CompositionDocumentR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/CompositionDocumentR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ConsentInterceptorResourceProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ConsentInterceptorResourceProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ConsentInterceptorResourceProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ConsentInterceptorResourceProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java similarity index 92% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java index 33a3fd4c5a0..4dbe3316f9a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/CorsR4Test.java @@ -1,16 +1,13 @@ package ca.uhn.fhir.jpa.provider.r4; -import static org.junit.jupiter.api.Assertions.assertEquals; - -import java.io.IOException; - import org.apache.commons.io.IOUtils; import org.apache.http.client.methods.CloseableHttpResponse; import org.apache.http.client.methods.HttpGet; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.Test; -import ca.uhn.fhir.util.TestUtil; +import java.io.IOException; + +import static org.junit.jupiter.api.Assertions.assertEquals; public class CorsR4Test extends BaseResourceProviderR4Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java similarity index 54% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java index 68af9686e67..cc6b457b68a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/DiffProviderR4Test.java @@ -2,6 +2,7 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.model.entity.ResourceHistoryTable; +import ca.uhn.fhir.jpa.patch.FhirPatchApplyR4Test; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.provider.ProviderConstants; import org.hl7.fhir.instance.model.api.IIdType; @@ -11,12 +12,11 @@ import org.hl7.fhir.r4.model.IdType; import org.hl7.fhir.r4.model.Parameters; import org.hl7.fhir.r4.model.Patient; import org.hl7.fhir.r4.model.StringType; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import static ca.uhn.fhir.jpa.patch.FhirPatchApplyR4Test.extractPartValue; -import static ca.uhn.fhir.jpa.patch.FhirPatchApplyR4Test.extractPartValuePrimitive; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; @@ -44,15 +44,15 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(2, diff.getParameter().size()); - assertEquals("replace", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient.text.div", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals("
", extractPartValuePrimitive(diff, 0, "operation", "previousValue")); - assertEquals("
SMITH
", extractPartValuePrimitive(diff, 0, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient.text.div", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals("
", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "previousValue")); + Assertions.assertEquals("
SMITH
", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "value")); - assertEquals("insert", extractPartValuePrimitive(diff, 1, "operation", "type")); - assertEquals("Patient.name", extractPartValuePrimitive(diff, 1, "operation", "path")); - assertEquals("0", extractPartValuePrimitive(diff, 1, "operation", "index")); - assertEquals("SMITH", extractPartValue(diff, 1, "operation", "value", HumanName.class).getFamily()); + Assertions.assertEquals("insert", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 1, "operation", "type")); + Assertions.assertEquals("Patient.name", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 1, "operation", "path")); + Assertions.assertEquals("0", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 1, "operation", "index")); + Assertions.assertEquals("SMITH", FhirPatchApplyR4Test.extractPartValue(diff, 1, "operation", "value", HumanName.class).getFamily()); } @@ -75,23 +75,23 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(4, diff.getParameter().size()); - assertEquals("replace", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient.meta.versionId", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals("2", extractPartValuePrimitive(diff, 0, "operation", "previousValue")); - assertEquals("3", extractPartValuePrimitive(diff, 0, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient.meta.versionId", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals("2", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "previousValue")); + Assertions.assertEquals("3", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "value")); - assertEquals("replace", extractPartValuePrimitive(diff, 1, "operation", "type")); - assertEquals("Patient.meta.lastUpdated", extractPartValuePrimitive(diff, 1, "operation", "path")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 1, "operation", "type")); + Assertions.assertEquals("Patient.meta.lastUpdated", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 1, "operation", "path")); - assertEquals("replace", extractPartValuePrimitive(diff, 2, "operation", "type")); - assertEquals("Patient.text.div", extractPartValuePrimitive(diff, 2, "operation", "path")); - assertEquals("
", extractPartValuePrimitive(diff, 2, "operation", "previousValue")); - assertEquals("
SMITH
", extractPartValuePrimitive(diff, 2, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 2, "operation", "type")); + Assertions.assertEquals("Patient.text.div", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 2, "operation", "path")); + Assertions.assertEquals("
", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 2, "operation", "previousValue")); + Assertions.assertEquals("
SMITH
", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 2, "operation", "value")); - assertEquals("insert", extractPartValuePrimitive(diff, 3, "operation", "type")); - assertEquals("Patient.name", extractPartValuePrimitive(diff, 3, "operation", "path")); - assertEquals("0", extractPartValuePrimitive(diff, 3, "operation", "index")); - assertEquals("SMITH", extractPartValue(diff, 3, "operation", "value", HumanName.class).getFamily()); + Assertions.assertEquals("insert", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 3, "operation", "type")); + Assertions.assertEquals("Patient.name", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 3, "operation", "path")); + Assertions.assertEquals("0", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 3, "operation", "index")); + Assertions.assertEquals("SMITH", FhirPatchApplyR4Test.extractPartValue(diff, 3, "operation", "value", HumanName.class).getFamily()); } @@ -118,10 +118,10 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(5, diff.getParameter().size()); - assertEquals("replace", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient.meta.versionId", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals("1", extractPartValuePrimitive(diff, 0, "operation", "previousValue")); - assertEquals("3", extractPartValuePrimitive(diff, 0, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient.meta.versionId", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals("1", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "previousValue")); + Assertions.assertEquals("3", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "value")); } @@ -142,9 +142,9 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(1, diff.getParameter().size()); - assertEquals("insert", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals(true, extractPartValue(diff, 0, "operation", "value", Patient.class).getActive()); + Assertions.assertEquals("insert", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals(true, FhirPatchApplyR4Test.extractPartValue(diff, 0, "operation", "value", Patient.class).getActive()); } @@ -168,10 +168,10 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(5, diff.getParameter().size()); - assertEquals("replace", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient.meta.versionId", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals("1", extractPartValuePrimitive(diff, 0, "operation", "previousValue")); - assertEquals("3", extractPartValuePrimitive(diff, 0, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient.meta.versionId", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals("1", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "previousValue")); + Assertions.assertEquals("3", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "value")); } @@ -195,10 +195,10 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(3, diff.getParameter().size()); - assertEquals("replace", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient.id", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals("A", extractPartValuePrimitive(diff, 0, "operation", "previousValue")); - assertEquals("B", extractPartValuePrimitive(diff, 0, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient.id", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals("A", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "previousValue")); + Assertions.assertEquals("B", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "value")); } @@ -224,10 +224,10 @@ public class DiffProviderR4Test extends BaseResourceProviderR4Test { assertEquals(3, diff.getParameter().size()); - assertEquals("replace", extractPartValuePrimitive(diff, 0, "operation", "type")); - assertEquals("Patient.id", extractPartValuePrimitive(diff, 0, "operation", "path")); - assertEquals("A", extractPartValuePrimitive(diff, 0, "operation", "previousValue")); - assertEquals("B", extractPartValuePrimitive(diff, 0, "operation", "value")); + Assertions.assertEquals("replace", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "type")); + Assertions.assertEquals("Patient.id", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "path")); + Assertions.assertEquals("A", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "previousValue")); + Assertions.assertEquals("B", FhirPatchApplyR4Test.extractPartValuePrimitive(diff, 0, "operation", "value")); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java index d0fb591cb8a..9bab54b7a0a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/EmptyIndexesR4Test.java @@ -2,10 +2,10 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.rp.r4.ObservationResourceProvider; import ca.uhn.fhir.jpa.rp.r4.OrganizationResourceProvider; import ca.uhn.fhir.jpa.rp.r4.PatientResourceProvider; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.EncodingEnum; import ca.uhn.fhir.rest.client.api.IGenericClient; import ca.uhn.fhir.rest.client.interceptor.SimpleRequestHeaderInterceptor; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ExpungeR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ExpungeR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ExpungeR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ExpungeR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java index 4e730953429..9826988eae6 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/GraphQLR4Test.java @@ -22,8 +22,8 @@ import org.slf4j.LoggerFactory; import java.io.IOException; import java.nio.charset.StandardCharsets; -import static ca.uhn.fhir.jpa.provider.GraphQLR4ProviderTest.DATA_PREFIX; -import static ca.uhn.fhir.jpa.provider.GraphQLR4ProviderTest.DATA_SUFFIX; +import static ca.uhn.fhir.jpa.provider.GraphQLProviderTestUtil.DATA_PREFIX; +import static ca.uhn.fhir.jpa.provider.GraphQLProviderTestUtil.DATA_SUFFIX; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; import static org.hamcrest.Matchers.not; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/HookInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/HookInterceptorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/HookInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/HookInterceptorR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MemberMatcherR4HelperTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MemberMatcherR4HelperTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MemberMatcherR4HelperTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MemberMatcherR4HelperTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java similarity index 90% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java index 7f922b6c0d8..2dd1bb34162 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantBatchOperationR4Test.java @@ -12,6 +12,7 @@ import ca.uhn.fhir.rest.api.CacheControlDirective; import ca.uhn.fhir.rest.api.server.RequestDetails; import ca.uhn.fhir.rest.server.provider.ProviderConstants; import ca.uhn.fhir.rest.server.servlet.ServletRequestDetails; +import org.hamcrest.MatcherAssert; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.hapi.rest.server.helper.BatchHelperR4; import org.hl7.fhir.r4.model.Bundle; @@ -133,11 +134,11 @@ public class MultitenantBatchOperationR4Test extends BaseMultitenantResourceProv // The searchparam value is on the observation, but it hasn't been indexed yet myTenantClientInterceptor.setTenantId(TENANT_A); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); myTenantClientInterceptor.setTenantId(TENANT_B); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); myTenantClientInterceptor.setTenantId(DEFAULT_PARTITION_NAME); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); // setup Parameters input = new Parameters(); @@ -159,12 +160,12 @@ public class MultitenantBatchOperationR4Test extends BaseMultitenantResourceProv List alleleObservationIds = reindexTestHelper.getAlleleObservationIds(myClient); // Only the one in the first tenant should be indexed myTenantClientInterceptor.setTenantId(TENANT_A); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(1)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(1)); assertEquals(obsFinalA.getIdPart(), alleleObservationIds.get(0)); myTenantClientInterceptor.setTenantId(TENANT_B); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); myTenantClientInterceptor.setTenantId(DEFAULT_PARTITION_NAME); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); // Reindex default partition myTenantClientInterceptor.setTenantId(DEFAULT_PARTITION_NAME); @@ -181,7 +182,7 @@ public class MultitenantBatchOperationR4Test extends BaseMultitenantResourceProv myTenantClientInterceptor.setTenantId(DEFAULT_PARTITION_NAME); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(1)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(1)); } @Test @@ -199,9 +200,9 @@ public class MultitenantBatchOperationR4Test extends BaseMultitenantResourceProv // The searchparam value is on the observation, but it hasn't been indexed yet myTenantClientInterceptor.setTenantId(TENANT_A); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); myTenantClientInterceptor.setTenantId(TENANT_B); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); // setup Parameters input = new Parameters(); @@ -226,10 +227,10 @@ public class MultitenantBatchOperationR4Test extends BaseMultitenantResourceProv List alleleObservationIds = reindexTestHelper.getAlleleObservationIds(myClient); // Only the one in the first tenant should be indexed myTenantClientInterceptor.setTenantId(TENANT_A); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(1)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(1)); assertEquals(obsFinalA.getIdPart(), alleleObservationIds.get(0)); myTenantClientInterceptor.setTenantId(TENANT_B); - assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); + MatcherAssert.assertThat(reindexTestHelper.getAlleleObservationIds(myClient), hasSize(0)); } private Bundle getAllPatientsInTenant(String theTenantId) { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantServerR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantServerR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantServerR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/MultitenantServerR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/NicknameSearchR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/NicknameSearchR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/NicknameSearchR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/NicknameSearchR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/OpenApiInterceptorJpaTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/OpenApiInterceptorJpaTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/OpenApiInterceptorJpaTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/OpenApiInterceptorJpaTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatchProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatchProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatchProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatchProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientEverythingR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientEverythingR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientEverythingR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientEverythingR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientMemberMatchOperationR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientMemberMatchOperationR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientMemberMatchOperationR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/PatientMemberMatchOperationR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java index 17408adbfb9..72a38cbd65c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/QuestionnaireResourceProviderR4.java @@ -1,7 +1,7 @@ package ca.uhn.fhir.jpa.provider.r4; -import org.hl7.fhir.r4.model.Questionnaire; import org.hl7.fhir.instance.model.api.IBaseResource; +import org.hl7.fhir.r4.model.Questionnaire; public class QuestionnaireResourceProviderR4 extends JpaResourceProviderR4 { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/RemoteTerminologyServiceResourceProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/RemoteTerminologyServiceResourceProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/RemoteTerminologyServiceResourceProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/RemoteTerminologyServiceResourceProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderConcurrencyR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderConcurrencyR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderConcurrencyR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderConcurrencyR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderCustomSearchParamR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderCustomSearchParamR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderCustomSearchParamR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderCustomSearchParamR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderExpungeR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderExpungeR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderExpungeR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderExpungeR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderHasParamR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderHasParamR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderHasParamR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderHasParamR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInterceptorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInterceptorR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInvalidDataR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInvalidDataR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInvalidDataR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderInvalidDataR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderOnlySomeResourcesProvidedR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderOnlySomeResourcesProvidedR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderOnlySomeResourcesProvidedR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderOnlySomeResourcesProvidedR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderQuestionnaireResponseR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderQuestionnaireResponseR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderQuestionnaireResponseR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderQuestionnaireResponseR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4BundleTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4BundleTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4BundleTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4BundleTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CacheTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CacheTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CacheTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CacheTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemDesignationTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemDesignationTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemDesignationTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemDesignationTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java index 3e5f9596ce1..342e50b84a8 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemTest.java @@ -2,9 +2,9 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; -import ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.model.util.JpaConstants; +import ca.uhn.fhir.jpa.term.TermTestUtil; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; import org.apache.commons.io.IOUtils; @@ -75,7 +75,7 @@ public class ResourceProviderR4CodeSystemTest extends BaseResourceProviderR4Test .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .execute(); String resp = myFhirContext.newXmlParser().setPrettyPrint(true).encodeResourceToString(respParam); @@ -96,7 +96,7 @@ public class ResourceProviderR4CodeSystemTest extends BaseResourceProviderR4Test .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .useHttpGet() .execute(); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java index 0cf7519d6cc..405877eaa98 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4CodeSystemVersionedTest.java @@ -2,9 +2,9 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; -import ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.model.util.JpaConstants; +import ca.uhn.fhir.jpa.term.TermTestUtil; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; import org.apache.commons.io.IOUtils; @@ -101,7 +101,7 @@ public class ResourceProviderR4CodeSystemVersionedTest extends BaseResourceProvi .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .execute(); String resp = myFhirContext.newXmlParser().setPrettyPrint(true).encodeResourceToString(respParam); @@ -122,7 +122,7 @@ public class ResourceProviderR4CodeSystemVersionedTest extends BaseResourceProvi .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .useHttpGet() .execute(); @@ -144,7 +144,7 @@ public class ResourceProviderR4CodeSystemVersionedTest extends BaseResourceProvi .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .andParameter("version", new StringType("1")) .execute(); @@ -166,7 +166,7 @@ public class ResourceProviderR4CodeSystemVersionedTest extends BaseResourceProvi .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .andParameter("version", new StringType("1")) .useHttpGet() .execute(); @@ -189,7 +189,7 @@ public class ResourceProviderR4CodeSystemVersionedTest extends BaseResourceProvi .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .andParameter("version", new StringType("2")) .execute(); @@ -211,7 +211,7 @@ public class ResourceProviderR4CodeSystemVersionedTest extends BaseResourceProvi .onType(CodeSystem.class) .named("lookup") .withParameter(Parameters.class, "code", new CodeType("ParentA")) - .andParameter("system", new UriType(FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM)) + .andParameter("system", new UriType(TermTestUtil.URL_MY_CODE_SYSTEM)) .andParameter("version", new StringType("2")) .useHttpGet() .execute(); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ConceptMapTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ConceptMapTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ConceptMapTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ConceptMapTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java similarity index 77% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java index e9725f9b219..4c3feda82cf 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4DistanceTest.java @@ -1,6 +1,6 @@ package ca.uhn.fhir.jpa.provider.r4; -import ca.uhn.fhir.jpa.util.CoordCalculatorTest; +import ca.uhn.fhir.jpa.util.CoordCalculatorTestUtil; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.Bundle; import org.hl7.fhir.r4.model.Location; @@ -22,16 +22,16 @@ public class ResourceProviderR4DistanceTest extends BaseResourceProviderR4Test { @Test public void testNearSearchApproximate() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); IIdType locId = myClient.create().resource(loc).execute().getId().toUnqualifiedVersionless(); { // In the box - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; String url = "/Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + bigEnoughDistance; Bundle actual = myClient @@ -46,9 +46,9 @@ public class ResourceProviderR4DistanceTest extends BaseResourceProviderR4Test { assertEquals(locId.getIdPart(), actual.getEntry().get(0).getResource().getIdElement().getIdPart()); } { // Outside the box - double tooSmallDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN / 2; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN / 2; String url = "/Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + tooSmallDistance; myCaptureQueriesListener.clear(); @@ -68,8 +68,8 @@ public class ResourceProviderR4DistanceTest extends BaseResourceProviderR4Test { @Test public void testNearSearchDistanceNoDistanceChained() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_CHIN; - double longitude = CoordCalculatorTest.LONGITUDE_CHIN; + double latitude = CoordCalculatorTestUtil.LATITUDE_CHIN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_CHIN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); IIdType locId = myClient.create().resource(loc).execute().getId().toUnqualifiedVersionless(); @@ -96,8 +96,8 @@ public class ResourceProviderR4DistanceTest extends BaseResourceProviderR4Test { @Test public void testNearSearchApproximateChained() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); myCaptureQueriesListener.clear(); @@ -108,9 +108,9 @@ public class ResourceProviderR4DistanceTest extends BaseResourceProviderR4Test { pr.addLocation().setReference(locId.getValue()); IIdType prId = myPractitionerRoleDao.create(pr).getId().toUnqualifiedVersionless(); { // In the box - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; String url = "PractitionerRole?location." + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + bigEnoughDistance; myCaptureQueriesListener.clear(); @@ -128,9 +128,9 @@ public class ResourceProviderR4DistanceTest extends BaseResourceProviderR4Test { } { // Outside the box - double tooSmallDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN / 2; + double tooSmallDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN / 2; String url = "PractitionerRole?location." + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" + CoordCalculatorTest.LONGITUDE_CHIN + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + tooSmallDistance; myCaptureQueriesListener.clear(); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4RemoteTerminologyTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4RemoteTerminologyTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4RemoteTerminologyTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4RemoteTerminologyTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4SearchContainedTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4SearchContainedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4SearchContainedTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4SearchContainedTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4StructureDefinitionTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4StructureDefinitionTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4StructureDefinitionTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4StructureDefinitionTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java index 16ba5ef1596..de76a45fae0 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4Test.java @@ -152,7 +152,6 @@ import org.springframework.transaction.support.TransactionCallbackWithoutResult; import org.springframework.transaction.support.TransactionTemplate; import javax.annotation.Nonnull; -import javax.sql.DataSource; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetHSearchDisabledTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetHSearchDisabledTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetHSearchDisabledTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetHSearchDisabledTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java index 3983ab8ae4e..3e7479ad725 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetNoVerCSNoVerTest.java @@ -60,8 +60,6 @@ import java.util.List; import java.util.Optional; import java.util.stream.Collectors; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_VALUE_SET; import static ca.uhn.fhir.util.HapiExtensions.EXT_VALUESET_EXPANSION_MESSAGE; import static org.awaitility.Awaitility.await; import static org.hamcrest.MatcherAssert.assertThat; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java index 7c3929d3984..0ae46d0fcdc 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSNoVerTest.java @@ -52,8 +52,6 @@ import javax.annotation.Nonnull; import java.io.IOException; import java.util.Optional; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_VALUE_SET; import static org.awaitility.Awaitility.await; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java index 248d1d89c87..52dfac62b68 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderR4ValueSetVerCSVerTest.java @@ -45,8 +45,6 @@ import javax.annotation.Nonnull; import java.io.IOException; import java.util.Optional; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_VALUE_SET; import static org.awaitility.Awaitility.await; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSearchModifierR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSearchModifierR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSearchModifierR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSearchModifierR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java index 8f0c4ac3487..219ab097ce3 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ResourceProviderSummaryModeR4Test.java @@ -4,9 +4,7 @@ import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.search.SearchCoordinatorSvcImpl; import ca.uhn.fhir.rest.api.SearchTotalModeEnum; import ca.uhn.fhir.rest.api.SummaryEnum; -import ca.uhn.fhir.rest.gclient.ICriterion; import ca.uhn.fhir.rest.gclient.StringClientParam; -import ca.uhn.fhir.rest.param.StringParam; import com.google.common.collect.Lists; import org.hl7.fhir.r4.model.Bundle; import org.hl7.fhir.r4.model.Narrative; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerCapabilityStatementProviderJpaR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerCapabilityStatementProviderJpaR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerCapabilityStatementProviderJpaR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerCapabilityStatementProviderJpaR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/ServerR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/StaleSearchDeletingSvcR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/StaleSearchDeletingSvcR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/StaleSearchDeletingSvcR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/StaleSearchDeletingSvcR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SubscriptionsR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SubscriptionsR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SubscriptionsR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SubscriptionsR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java index 1cef351257e..43c3706f566 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderR4Test.java @@ -6,7 +6,6 @@ import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.interceptor.api.Hook; import ca.uhn.fhir.interceptor.api.Pointcut; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.provider.SystemProviderDstu2Test; import ca.uhn.fhir.jpa.rp.r4.BinaryResourceProvider; import ca.uhn.fhir.jpa.rp.r4.DiagnosticReportResourceProvider; import ca.uhn.fhir.jpa.rp.r4.LocationResourceProvider; @@ -730,7 +729,7 @@ public class SystemProviderR4Test extends BaseJpaR4Test { ourRestServer.registerInterceptor(interceptor); try { - InputStream bundleRes = SystemProviderDstu2Test.class.getResourceAsStream("/questionnaire-sdc-profile-example-ussg-fht.xml"); + InputStream bundleRes = SystemProviderR4Test.class.getResourceAsStream("/questionnaire-sdc-profile-example-ussg-fht.xml"); String bundleStr = IOUtils.toString(bundleRes, StandardCharsets.UTF_8); HttpPost req = new HttpPost(ourServerBase); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java index 87332af2446..b2dc493bae2 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/SystemProviderTransactionSearchR4Test.java @@ -2,13 +2,13 @@ package ca.uhn.fhir.jpa.provider.r4; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.rp.r4.MedicationRequestResourceProvider; import ca.uhn.fhir.jpa.rp.r4.MedicationResourceProvider; import ca.uhn.fhir.jpa.rp.r4.ObservationResourceProvider; import ca.uhn.fhir.jpa.rp.r4.OrganizationResourceProvider; import ca.uhn.fhir.jpa.rp.r4.PatientResourceProvider; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.EncodingEnum; import ca.uhn.fhir.rest.client.api.IGenericClient; import ca.uhn.fhir.rest.client.interceptor.SimpleRequestHeaderInterceptor; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/TerminologyUploaderProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/TerminologyUploaderProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r4/TerminologyUploaderProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/provider/r4/TerminologyUploaderProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java index 0d18e78d4b0..f75df37fe4e 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/reindex/ReindexStepTest.java @@ -8,10 +8,10 @@ import ca.uhn.fhir.batch2.jobs.reindex.ReindexStep; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.test.BaseJpaR4Test; -import ca.uhn.fhir.model.dstu2.resource.Patient; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.Enumerations; import org.hl7.fhir.r4.model.IdType; +import org.hl7.fhir.r4.model.Patient; import org.hl7.fhir.r4.model.SearchParameter; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Test; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/reindex/ResourceReindexSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/reindex/ResourceReindexSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/reindex/ResourceReindexSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/reindex/ResourceReindexSvcImplTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/search/ExtendedHSearchResourceProjectionTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/ExtendedHSearchResourceProjectionTest.java similarity index 92% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/search/ExtendedHSearchResourceProjectionTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/ExtendedHSearchResourceProjectionTest.java index 164a940d124..5a533c6658b 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/search/ExtendedHSearchResourceProjectionTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/ExtendedHSearchResourceProjectionTest.java @@ -1,7 +1,9 @@ -package ca.uhn.fhir.jpa.dao.search; +package ca.uhn.fhir.jpa.search; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.i18n.Msg; +import ca.uhn.fhir.jpa.dao.search.ExtendedHSearchResourceProjection; +import ca.uhn.fhir.jpa.dao.search.ResourceNotFoundInIndexException; import ca.uhn.fhir.parser.IParser; import org.hl7.fhir.instance.model.api.IBaseResource; import org.hl7.fhir.r4.model.Observation; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/r4/PagingMultinodeProviderR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/r4/PagingMultinodeProviderR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/r4/PagingMultinodeProviderR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/r4/PagingMultinodeProviderR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java index 3e51c969f74..907b9176b46 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/search/reindex/ResourceReindexingSvcImplTest.java @@ -4,13 +4,13 @@ import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.api.dao.DaoRegistry; import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; import ca.uhn.fhir.jpa.dao.BaseHapiFhirDao; -import ca.uhn.fhir.jpa.test.BaseJpaTest; import ca.uhn.fhir.jpa.dao.data.IForcedIdDao; import ca.uhn.fhir.jpa.dao.data.IResourceReindexJobDao; import ca.uhn.fhir.jpa.dao.data.IResourceTableDao; import ca.uhn.fhir.jpa.entity.ResourceReindexJobEntity; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.model.sched.ISchedulerService; +import ca.uhn.fhir.jpa.test.BaseJpaTest; import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import ca.uhn.fhir.rest.server.util.ISearchParamRegistry; import org.apache.commons.lang3.time.DateUtils; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/GiantTransactionPerfTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/GiantTransactionPerfTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/GiantTransactionPerfTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/GiantTransactionPerfTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/README.txt b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/README.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/README.txt rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/README.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestParserTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestParserTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestParserTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestParserTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/stresstest/StressTestR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java similarity index 92% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java index 9bad30dd6ae..fa8ea305503 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/FhirR4Util.java @@ -5,7 +5,12 @@ import ca.uhn.fhir.rest.client.api.IGenericClient; import org.hl7.fhir.instance.model.api.IBaseCoding; import org.hl7.fhir.instance.model.api.IBaseMetaType; import org.hl7.fhir.instance.model.api.IBaseResource; -import org.hl7.fhir.r4.model.*; +import org.hl7.fhir.r4.model.Coding; +import org.hl7.fhir.r4.model.Enumerations; +import org.hl7.fhir.r4.model.Identifier; +import org.hl7.fhir.r4.model.Observation; +import org.hl7.fhir.r4.model.Patient; +import org.hl7.fhir.r4.model.Subscription; public class FhirR4Util { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java index 47f8526f71d..01f24aa442b 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/SubscriptionValidatingInterceptorTest.java @@ -30,7 +30,6 @@ import static org.hamcrest.Matchers.containsString; import static org.junit.jupiter.api.Assertions.assertDoesNotThrow; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; -import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.eq; import static org.mockito.ArgumentMatchers.isA; import static org.mockito.Mockito.never; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java index ed1c14b68af..6d5d34154c1 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/module/matcher/InMemorySubscriptionMatcherR4Test.java @@ -17,7 +17,7 @@ import ca.uhn.fhir.jpa.subscription.model.CanonicalSubscription; import ca.uhn.fhir.jpa.subscription.model.ResourceModifiedMessage; import ca.uhn.fhir.jpa.test.config.TestHSearchAddInConfig; import ca.uhn.fhir.jpa.test.config.TestR4Config; -import ca.uhn.fhir.jpa.util.CoordCalculatorTest; +import ca.uhn.fhir.jpa.util.CoordCalculatorTestUtil; import ca.uhn.fhir.model.api.TemporalPrecisionEnum; import ca.uhn.fhir.rest.param.CompositeParam; import ca.uhn.fhir.rest.param.DateParam; @@ -340,15 +340,15 @@ public class InMemorySubscriptionMatcherR4Test { @Test public void testLocationPositionNotSupported() { Location loc = new Location(); - double latitude = CoordCalculatorTest.LATITUDE_UHN; - double longitude = CoordCalculatorTest.LONGITUDE_UHN; + double latitude = CoordCalculatorTestUtil.LATITUDE_UHN; + double longitude = CoordCalculatorTestUtil.LONGITUDE_UHN; Location.LocationPositionComponent position = new Location.LocationPositionComponent().setLatitude(latitude).setLongitude(longitude); loc.setPosition(position); - double bigEnoughDistance = CoordCalculatorTest.DISTANCE_KM_CHIN_TO_UHN * 2; + double bigEnoughDistance = CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN * 2; SearchParameterMap params = myMatchUrlService.translateMatchUrl( "Location?" + - Location.SP_NEAR + "=" + CoordCalculatorTest.LATITUDE_CHIN + "|" - + CoordCalculatorTest.LONGITUDE_CHIN + "|" + + Location.SP_NEAR + "=" + CoordCalculatorTestUtil.LATITUDE_CHIN + "|" + + CoordCalculatorTestUtil.LONGITUDE_CHIN + "|" + bigEnoughDistance, myFhirContext.getResourceDefinition("Location")); assertUnsupported(loc, params); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java index a39eba2268d..dffc66efc20 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookActivatesPreExistingSubscriptionsR4Test.java @@ -2,8 +2,8 @@ package ca.uhn.fhir.jpa.subscription.resthook; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.provider.r4.BaseResourceProviderR4Test; -import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.jpa.subscription.submit.interceptor.SubscriptionMatcherInterceptor; +import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; import ca.uhn.fhir.rest.annotation.ResourceParam; import ca.uhn.fhir.rest.annotation.Update; import ca.uhn.fhir.rest.api.Constants; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java index 387e8411a11..2f51fe8c0ca 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestWithInterceptorRegisteredToDaoConfigR4Test.java @@ -5,7 +5,6 @@ import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.provider.r4.BaseResourceProviderR4Test; import ca.uhn.fhir.jpa.test.util.SubscriptionTestUtil; -import ca.uhn.fhir.model.dstu2.valueset.ResourceTypeEnum; import ca.uhn.fhir.model.primitive.IdDt; import ca.uhn.fhir.rest.annotation.Create; import ca.uhn.fhir.rest.annotation.ResourceParam; @@ -24,6 +23,7 @@ import org.hl7.fhir.r4.model.Coding; import org.hl7.fhir.r4.model.IdType; import org.hl7.fhir.r4.model.Observation; import org.hl7.fhir.r4.model.Subscription; +import org.hl7.fhir.r4b.model.Enumerations; import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeAll; @@ -159,7 +159,7 @@ public class RestHookTestWithInterceptorRegisteredToDaoConfigR4Test extends Base waitForSize(0, ourCreatedObservations); waitForSize(3, ourUpdatedObservations); - myClient.delete().resourceById(new IdDt(ResourceTypeEnum.SUBSCRIPTION.getCode(), subscription2.getId())).execute(); + myClient.delete().resourceById(new IdDt(Enumerations.ResourceTypeEnum.SUBSCRIPTION.toCode(), subscription2.getId())).execute(); Observation observationTemp3 = sendObservation(code, "SNOMED-CT"); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithEventDefinitionR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithEventDefinitionR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithEventDefinitionR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithEventDefinitionR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java index 32dd2ce7671..efd400622e8 100755 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookWithInterceptorR4Test.java @@ -5,12 +5,12 @@ import ca.uhn.fhir.interceptor.api.Hook; import ca.uhn.fhir.interceptor.api.IInterceptorService; import ca.uhn.fhir.interceptor.api.Interceptor; import ca.uhn.fhir.interceptor.api.Pointcut; -import ca.uhn.fhir.jpa.test.util.StoppableSubscriptionDeliveringRestHookSubscriber; import ca.uhn.fhir.jpa.subscription.BaseSubscriptionsR4Test; import ca.uhn.fhir.jpa.subscription.model.CanonicalSubscription; import ca.uhn.fhir.jpa.subscription.model.ResourceDeliveryMessage; import ca.uhn.fhir.jpa.subscription.model.ResourceModifiedMessage; import ca.uhn.fhir.jpa.subscription.util.SubscriptionDebugLogInterceptor; +import ca.uhn.fhir.jpa.test.util.StoppableSubscriptionDeliveringRestHookSubscriber; import ca.uhn.fhir.rest.api.Constants; import ca.uhn.fhir.rest.api.MethodOutcome; import org.apache.commons.lang3.Validate; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java similarity index 95% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java index 159983905b3..109fe7ede0f 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithCriteriaR4Test.java @@ -8,7 +8,12 @@ import ca.uhn.fhir.rest.api.MethodOutcome; import org.eclipse.jetty.websocket.api.Session; import org.eclipse.jetty.websocket.client.ClientUpgradeRequest; import org.eclipse.jetty.websocket.client.WebSocketClient; -import org.hl7.fhir.r4.model.*; +import org.hl7.fhir.r4.model.CodeableConcept; +import org.hl7.fhir.r4.model.Coding; +import org.hl7.fhir.r4.model.Observation; +import org.hl7.fhir.r4.model.Patient; +import org.hl7.fhir.r4.model.Reference; +import org.hl7.fhir.r4.model.Subscription; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; @@ -19,8 +24,8 @@ import java.net.URI; import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; -import static org.hamcrest.Matchers.contains; import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.contains; // This is currently disabled as the criteria mechanism was a non-standard experiment diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java index ce8d0b0417c..200627c4f90 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/subscription/websocket/WebsocketWithSubscriptionIdR4Test.java @@ -26,8 +26,8 @@ import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; import static org.awaitility.Awaitility.await; -import static org.hamcrest.Matchers.contains; import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.contains; /** * Adds a FHIR subscription with criteria through the rest interface. Then creates a websocket with the id of the diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/BaseLoaderTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/BaseLoaderTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/BaseLoaderTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/BaseLoaderTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java index efc75618dce..4d6f115cd27 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/BaseTermR4Test.java @@ -1,11 +1,11 @@ package ca.uhn.fhir.jpa.term; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.entity.TermCodeSystemVersion; import ca.uhn.fhir.jpa.entity.TermConcept; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink; import ca.uhn.fhir.jpa.model.entity.ResourceTable; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.server.storage.ResourcePersistentId; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.CodeSystem; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ITermReadSvcTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ITermReadSvcTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ITermReadSvcTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ITermReadSvcTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermCodeSystemStorageSvcTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java index 8685b4d96ab..81f6cdba1b4 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermConceptMappingSvcImplTest.java @@ -39,9 +39,7 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; -import static org.mockito.Mockito.doReturn; import static org.mockito.Mockito.mock; -import static org.mockito.Mockito.spy; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermVersionAdapterSvcR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermVersionAdapterSvcR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TermVersionAdapterSvcR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TermVersionAdapterSvcR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java index b5aa6832bfd..d7767f42da8 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcCustomTest.java @@ -22,7 +22,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertSame; import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.eq; -import static org.mockito.Mockito.*; +import static org.mockito.Mockito.times; +import static org.mockito.Mockito.verify; +import static org.mockito.Mockito.when; @ExtendWith(MockitoExtension.class) public class TerminologyLoaderSvcCustomTest extends BaseLoaderTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java index 6baabe3e461..042756973aa 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcIcd10cmJpaTest.java @@ -1,10 +1,10 @@ package ca.uhn.fhir.jpa.term; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.entity.TermCodeSystem; import ca.uhn.fhir.jpa.entity.TermCodeSystemVersion; import ca.uhn.fhir.jpa.partition.SystemRequestDetails; import ca.uhn.fhir.jpa.term.api.ITermLoaderSvc; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.util.ClasspathUtil; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; @@ -15,7 +15,6 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNotEquals; public class TerminologyLoaderSvcIcd10cmJpaTest extends BaseJpaR4Test { private TermLoaderSvcImpl mySvc; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java index 5013efb3263..e636686ddc3 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcImgthlaTest.java @@ -10,8 +10,8 @@ import org.mockito.Mock; import java.io.IOException; -import static org.hamcrest.Matchers.containsString; import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.containsString; import static org.junit.jupiter.api.Assertions.fail; public class TerminologyLoaderSvcImgthlaTest extends BaseLoaderTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java similarity index 93% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java index b14fec735fd..74e935bcbdb 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincJpaTest.java @@ -1,9 +1,9 @@ package ca.uhn.fhir.jpa.term; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.entity.TermCodeSystem; import ca.uhn.fhir.jpa.entity.TermCodeSystemVersion; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.test.utilities.BatchJobHelper; import org.hl7.fhir.r4.model.CodeSystem; @@ -33,7 +33,7 @@ public class TerminologyLoaderSvcLoincJpaTest extends BaseJpaR4Test { public void testLoadLoincMultipleVersions() throws IOException { // Load LOINC marked as version 2.67 - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); @@ -59,7 +59,7 @@ public class TerminologyLoaderSvcLoincJpaTest extends BaseJpaR4Test { // Update LOINC marked as version 2.67 myFiles = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveAllDeferred(); @@ -86,7 +86,7 @@ public class TerminologyLoaderSvcLoincJpaTest extends BaseJpaR4Test { // Load LOINC marked as version 2.68 myFiles = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v268_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v268_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveAllDeferred(); myBatchJobHelper.awaitAllBulkJobCompletions(false, TERM_CODE_SYSTEM_VERSION_DELETE_JOB_NAME ); @@ -118,7 +118,7 @@ public class TerminologyLoaderSvcLoincJpaTest extends BaseJpaR4Test { public void testLoadLoincVersionNotCurrent() throws IOException { // Load LOINC marked as version 2.67 - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); @@ -153,7 +153,7 @@ public class TerminologyLoaderSvcLoincJpaTest extends BaseJpaR4Test { // Load LOINC marked as version 2.68 and not making it current (so 2.67 should remain current) myFiles = new ZipCollectionBuilder(); - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesWithPropertiesFileToZip( + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip( myFiles, "v268_curr_false_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveAllDeferred(); @@ -195,7 +195,7 @@ public class TerminologyLoaderSvcLoincJpaTest extends BaseJpaR4Test { myFiles.addFileZip("/loinc/", "loinc.xml"); // Load LOINC marked as version 2.67 - TerminologyLoaderSvcLoincTest.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, null); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, null); mySvc.loadLoinc(myFiles.getFiles(), mySrd); myTerminologyDeferredStorageSvc.saveAllDeferred(); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java similarity index 79% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java index 0ec8d4f1703..ba897891a4f 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcLoincTest.java @@ -4,7 +4,6 @@ import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.entity.TermCodeSystemVersion; import ca.uhn.fhir.jpa.entity.TermConcept; -import ca.uhn.fhir.jpa.entity.TermConceptDesignation; import ca.uhn.fhir.jpa.entity.TermConceptProperty; import ca.uhn.fhir.jpa.model.util.JpaConstants; import ca.uhn.fhir.jpa.term.api.ITermCodeSystemStorageSvc; @@ -35,41 +34,18 @@ import org.mockito.Mock; import java.io.IOException; import java.util.ArrayList; -import java.util.Collection; import java.util.List; import java.util.Map; import java.util.Properties; import static ca.uhn.fhir.jpa.term.api.ITermCodeSystemStorageSvc.MAKE_LOADING_VERSION_CURRENT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_DUPLICATE_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_LINK_DUPLICATE_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_LINK_FILE_DEFAULT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_CODESYSTEM_MAKE_CURRENT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_CODESYSTEM_VERSION; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_CONSUMER_NAME_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_DOCUMENT_ONTOLOGY_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_DUPLICATE_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_FILE_DEFAULT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_GROUP_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_GROUP_TERMS_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_HIERARCHY_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_IEEE_MEDICAL_DEVICE_CODE_MAPPING_TABLE_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_IMAGING_DOCUMENT_CODES_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_LINGUISTIC_VARIANTS_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PARENT_GROUP_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_FILE_DEFAULT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_LINK_FILE_DEFAULT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_LINK_FILE_PRIMARY_DEFAULT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_RELATED_CODE_MAPPING_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_RSNA_PLAYBOOK_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_TOP2000_COMMON_LAB_RESULTS_SI_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_TOP2000_COMMON_LAB_RESULTS_US_FILE_DEFAULT; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_UNIVERSAL_LAB_ORDER_VALUESET_FILE_DEFAULT; import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_UPLOAD_PROPERTIES_FILE; -import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_XML_FILE; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.contains; import static org.hamcrest.Matchers.containsString; @@ -133,19 +109,19 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { @Test public void testLoadLoincWithSplitPartLink() throws Exception { - addLoincMandatoryFilesToZip(myFiles); + TermTestUtil.addLoincMandatoryFilesToZip(myFiles); verifyLoadLoinc(); } @Test public void testLoadLoincWithSinglePartLink() throws Exception { - addLoincMandatoryFilesAndSinglePartLinkToZip(myFiles); + TermTestUtil.addLoincMandatoryFilesAndSinglePartLinkToZip(myFiles); verifyLoadLoinc(); } @Test public void testLoadLoincWithMandatoryFilesOnly() throws Exception { - addLoincMandatoryFilesWithoutTop2000ToZip(myFiles); + TermTestUtil.addLoincMandatoryFilesWithoutTop2000ToZip(myFiles); verifyLoadLoinc(false, false); } @@ -153,7 +129,7 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { public void testLoadLoincInvalidPartLinkFiles() throws IOException { // Missing all PartLinkFiles - addBaseLoincMandatoryFilesToZip(myFiles, true); + TermTestUtil.addBaseLoincMandatoryFilesToZip(myFiles, true); myFiles.addFileZip("/loinc/", LOINC_UPLOAD_PROPERTIES_FILE.getCode()); try { @@ -186,7 +162,7 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { @Test public void testLoadLoincWithConsumerNameAndLinguisticVariants() throws Exception { - addLoincMandatoryFilesAndConsumerNameAndLinguisticVariants(myFiles); + TermTestUtil.addLoincMandatoryFilesAndConsumerNameAndLinguisticVariants(myFiles); verifyLoadLoinc(false, true); } @@ -483,16 +459,16 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { if (theIncludeConsumerNameAndLinguisticVariants) { code = concepts.get("61438-8"); assertEquals(8, code.getDesignations().size()); - verifyConsumerName(code.getDesignations(), "Consumer Name 61438-8"); - verifyLinguisticVariant(code.getDesignations(), "de-AT", "Entlassungsbrief Ärztlich","Ergebnis","Zeitpunkt","{Setting}","Dokument","Dermatologie","DOC.ONTOLOGY","de shortname","de long common name","de related names 2","de linguistic variant display name"); - verifyLinguisticVariant(code.getDesignations(), "fr-CA", "Cellules de Purkinje cytoplasmique type 2 , IgG","Titre","Temps ponctuel","Sérum","Quantitatif","Immunofluorescence","Sérologie","","","",""); - verifyLinguisticVariant(code.getDesignations(), "zh-CN", "血流速度.收缩期.最大值","速度","时间点","大脑中动脉","定量型","超声.多普勒","产科学检查与测量指标.超声","","", "Cereb 动态 可用数量表示的;定量性;数值型;数量型;连续数值型标尺 大脑(Cerebral) 时刻;随机;随意;瞬间 术语\"cerebral\"指的是主要由中枢半球(大脑皮质和基底神经节)组成的那部分脑结构 流 流量;流速;流体 血;全血 血流量;血液流量 速度(距离/时间);速率;速率(距离/时间)",""); + TermTestUtil.verifyConsumerName(code.getDesignations(), "Consumer Name 61438-8"); + TermTestUtil.verifyLinguisticVariant(code.getDesignations(), "de-AT", "Entlassungsbrief Ärztlich","Ergebnis","Zeitpunkt","{Setting}","Dokument","Dermatologie","DOC.ONTOLOGY","de shortname","de long common name","de related names 2","de linguistic variant display name"); + TermTestUtil.verifyLinguisticVariant(code.getDesignations(), "fr-CA", "Cellules de Purkinje cytoplasmique type 2 , IgG","Titre","Temps ponctuel","Sérum","Quantitatif","Immunofluorescence","Sérologie","","","",""); + TermTestUtil.verifyLinguisticVariant(code.getDesignations(), "zh-CN", "血流速度.收缩期.最大值","速度","时间点","大脑中动脉","定量型","超声.多普勒","产科学检查与测量指标.超声","","", "Cereb 动态 可用数量表示的;定量性;数值型;数量型;连续数值型标尺 大脑(Cerebral) 时刻;随机;随意;瞬间 术语\"cerebral\"指的是主要由中枢半球(大脑皮质和基底神经节)组成的那部分脑结构 流 流量;流速;流体 血;全血 血流量;血液流量 速度(距离/时间);速率;速率(距离/时间)",""); code = concepts.get("17787-3"); assertEquals(5, code.getDesignations().size()); - verifyConsumerName(code.getDesignations(), "Consumer Name 17787-3"); - verifyLinguisticVariant(code.getDesignations(), "de-AT", "","","","","","","","","","CoV OC43 RNA ql/SM P","Coronavirus OC43 RNA ql. /Sondermaterial PCR"); - verifyLinguisticVariant(code.getDesignations(), "fr-CA", "Virus respiratoire syncytial bovin","Présence-Seuil","Temps ponctuel","XXX","Ordinal","Culture spécifique à un microorganisme","Microbiologie","","","",""); - verifyLinguisticVariant(code.getDesignations(), "zh-CN", "血流速度.收缩期.最大值","速度","时间点","二尖瓣^胎儿","定量型","超声.多普勒","产科学检查与测量指标.超声","","","僧帽瓣 动态 可用数量表示的;定量性;数值型;数量型;连续数值型标尺 时刻;随机;随意;瞬间 流 流量;流速;流体 胎;超系统 - 胎儿 血;全血 血流量;血液流量 速度(距离/时间);速率;速率(距离/时间)",""); + TermTestUtil.verifyConsumerName(code.getDesignations(), "Consumer Name 17787-3"); + TermTestUtil.verifyLinguisticVariant(code.getDesignations(), "de-AT", "","","","","","","","","","CoV OC43 RNA ql/SM P","Coronavirus OC43 RNA ql. /Sondermaterial PCR"); + TermTestUtil.verifyLinguisticVariant(code.getDesignations(), "fr-CA", "Virus respiratoire syncytial bovin","Présence-Seuil","Temps ponctuel","XXX","Ordinal","Culture spécifique à un microorganisme","Microbiologie","","","",""); + TermTestUtil.verifyLinguisticVariant(code.getDesignations(), "zh-CN", "血流速度.收缩期.最大值","速度","时间点","二尖瓣^胎儿","定量型","超声.多普勒","产科学检查与测量指标.超声","","","僧帽瓣 动态 可用数量表示的;定量性;数值型;数量型;连续数值型标尺 时刻;随机;随意;瞬间 流 流量;流速;流体 胎;超系统 - 胎儿 血;全血 血流量;血液流量 速度(距离/时间);速率;速率(距离/时间)",""); } } @@ -501,7 +477,7 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { // Load LOINC marked as version 2.67 - addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); verify(myTermCodeSystemStorageSvc, times(2)).storeNewCodeSystemVersion(mySystemCaptor_267_first.capture(), myCsvCaptor.capture(), any(RequestDetails.class), myValueSetsCaptor_267_first.capture(), myConceptMapCaptor_267_first.capture()); @@ -552,7 +528,7 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { // Update LOINC marked as version 2.67 myFiles = new ZipCollectionBuilder(); - addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v267_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); verify(myTermCodeSystemStorageSvc, times(2)).storeNewCodeSystemVersion(mySystemCaptor_267_second.capture(), myCsvCaptor.capture(), any(RequestDetails.class), myValueSetsCaptor_267_second.capture(), myConceptMapCaptor_267_second.capture()); @@ -603,7 +579,7 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { // Load LOINC marked as version 2.68 myFiles = new ZipCollectionBuilder(); - addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v268_loincupload.properties"); + TermTestUtil.addLoincMandatoryFilesWithPropertiesFileToZip(myFiles, "v268_loincupload.properties"); mySvc.loadLoinc(myFiles.getFiles(), mySrd); verify(myTermCodeSystemStorageSvc, times(2)).storeNewCodeSystemVersion(mySystemCaptor_268.capture(), myCsvCaptor.capture(), any(RequestDetails.class), myValueSetsCaptor_268.capture(), myConceptMapCaptor_268.capture()); @@ -668,76 +644,10 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { } } - public static void addLoincMandatoryFilesAndSinglePartLinkToZip(ZipCollectionBuilder theFiles) throws IOException { - addBaseLoincMandatoryFilesToZip(theFiles, true); - theFiles.addFileZip("/loinc/", "loincupload_singlepartlink.properties"); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_DEFAULT.getCode()); - } - - public static void addLoincMandatoryFilesAndConsumerNameAndLinguisticVariants(ZipCollectionBuilder theFiles) throws IOException { - addBaseLoincMandatoryFilesToZip(theFiles, true); - theFiles.addFileZip("/loinc/", "loincupload_singlepartlink.properties"); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_CONSUMER_NAME_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT.getCode() + "zhCN5LinguisticVariant.csv"); - theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT.getCode() + "deAT24LinguisticVariant.csv"); - theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT.getCode() + "frCA8LinguisticVariant.csv"); - } - - - public static void addLoincMandatoryFilesToZip(ZipCollectionBuilder theFiles) throws IOException { - addBaseLoincMandatoryFilesToZip(theFiles, true); - theFiles.addFileZip("/loinc/", LOINC_UPLOAD_PROPERTIES_FILE.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_PRIMARY_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT.getCode()); - } - - public static void addLoincMandatoryFilesWithoutTop2000ToZip(ZipCollectionBuilder theFiles) throws IOException { - addBaseLoincMandatoryFilesToZip(theFiles, false); - theFiles.addFileZip("/loinc/", LOINC_UPLOAD_PROPERTIES_FILE.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_PRIMARY_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT.getCode()); - } - - public static void addLoincMandatoryFilesWithPropertiesFileToZip(ZipCollectionBuilder theFiles, String thePropertiesFile) throws IOException { - if (thePropertiesFile != null) { - theFiles.addFileZip("/loinc/", thePropertiesFile); - } - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_PRIMARY_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT.getCode()); - addBaseLoincMandatoryFilesToZip(theFiles, true); - } - - private static void addBaseLoincMandatoryFilesToZip(ZipCollectionBuilder theFiles, Boolean theIncludeTop2000) throws IOException{ - theFiles.addFileZip("/loinc/", LOINC_XML_FILE.getCode()); - theFiles.addFileZip("/loinc/", LOINC_GROUP_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_GROUP_TERMS_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PARENT_GROUP_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_DUPLICATE_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_HIERARCHY_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_DUPLICATE_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_LINK_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_LINK_DUPLICATE_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_PART_RELATED_CODE_MAPPING_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_DOCUMENT_ONTOLOGY_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_RSNA_PLAYBOOK_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_UNIVERSAL_LAB_ORDER_VALUESET_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_IEEE_MEDICAL_DEVICE_CODE_MAPPING_TABLE_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_IMAGING_DOCUMENT_CODES_FILE_DEFAULT.getCode()); - if (theIncludeTop2000) { - theFiles.addFileZip("/loinc/", LOINC_TOP2000_COMMON_LAB_RESULTS_SI_FILE_DEFAULT.getCode()); - theFiles.addFileZip("/loinc/", LOINC_TOP2000_COMMON_LAB_RESULTS_US_FILE_DEFAULT.getCode()); - } - - } @Test public void testLoadLoincMultiaxialHierarchySupport() throws Exception { - addLoincMandatoryFilesToZip(myFiles); + TermTestUtil.addLoincMandatoryFilesToZip(myFiles); // Actually do the load mySvc.loadLoinc(myFiles.getFiles(), mySrd); @@ -862,7 +772,7 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { @Test public void testDontMakeCurrentVersion() throws IOException { - addLoincMandatoryFilesToZip(myFiles); + TermTestUtil.addLoincMandatoryFilesToZip(myFiles); testProps.put(LOINC_CODESYSTEM_MAKE_CURRENT.getCode(), "false"); testProps.put(LOINC_CODESYSTEM_VERSION.getCode(), "27.0"); @@ -940,54 +850,4 @@ public class TerminologyLoaderSvcLoincTest extends BaseLoaderTest { } - - private static void verifyConsumerName(Collection designationList, String theConsumerName) { - - TermConceptDesignation consumerNameDesignation = null; - for (TermConceptDesignation designation : designationList) { - if ("ConsumerName".equals(designation.getUseDisplay() )) { - consumerNameDesignation = designation; - } - } - assertEquals(theConsumerName, consumerNameDesignation.getValue()); - } - - private static void verifyLinguisticVariant(Collection designationList, String theLanguage, - String theComponent, String theProperty, String theTimeAspct, String theSystem, String theScaleTyp, - String methodType, String theClass, String theShortName, String theLongCommonName, String theRelatedName2, - String theLinguisticVariantDisplayName) { - - TermConceptDesignation formalNameDes = null; - TermConceptDesignation shortNameDes = null; - TermConceptDesignation longCommonNameDes = null; - TermConceptDesignation linguisticVariantDisplayNameDes = null; - - for (TermConceptDesignation designation : designationList) { - if (theLanguage.equals(designation.getLanguage())) { - - if ("FullySpecifiedName".equals(designation.getUseDisplay())) - formalNameDes = designation; - - if ("SHORTNAME".equals(designation.getUseDisplay())) - shortNameDes = designation; - if ("LONG_COMMON_NAME".equals(designation.getUseDisplay())) - longCommonNameDes = designation; - if ("LinguisticVariantDisplayName".equals(designation.getUseDisplay())) - linguisticVariantDisplayNameDes = designation; - } - } - - verifyDesignation(formalNameDes, ITermLoaderSvc.LOINC_URI, "FullySpecifiedName", theComponent+":"+theProperty+":"+theTimeAspct+":"+theSystem+":"+theScaleTyp+":"+methodType); - verifyDesignation(shortNameDes, ITermLoaderSvc.LOINC_URI, "SHORTNAME", theShortName); - verifyDesignation(longCommonNameDes, ITermLoaderSvc.LOINC_URI, "LONG_COMMON_NAME", theLongCommonName); - verifyDesignation(linguisticVariantDisplayNameDes, ITermLoaderSvc.LOINC_URI, "LinguisticVariantDisplayName", theLinguisticVariantDisplayName); - } - - private static void verifyDesignation(TermConceptDesignation theDesignation, String theUseSystem, String theUseCode, String theValue) { - if (theDesignation == null) - return; - assertEquals(theUseSystem, theDesignation.getUseSystem()); - assertEquals(theUseCode, theDesignation.getUseCode()); - assertEquals(theValue, theDesignation.getValue()); - } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java index ad210a3d84c..7e589b2e8d0 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologyLoaderSvcSnomedCtTest.java @@ -10,7 +10,6 @@ import ca.uhn.fhir.rest.api.server.RequestDetails; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; import org.apache.commons.io.IOUtils; import org.hl7.fhir.r4.model.CodeSystem; -import org.hl7.fhir.r4.model.ConceptMap; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; @@ -27,11 +26,12 @@ import java.util.TreeSet; import java.util.zip.ZipOutputStream; import static org.hamcrest.CoreMatchers.containsString; +import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.hasItem; import static org.hamcrest.Matchers.not; -import static org.hamcrest.MatcherAssert.assertThat; import static org.junit.jupiter.api.Assertions.fail; -import static org.mockito.ArgumentMatchers.*; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.anyList; import static org.mockito.Mockito.verify; public class TerminologyLoaderSvcSnomedCtTest extends BaseLoaderTest { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java index 4122afa3691..53a32d543da 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcDeltaR4Test.java @@ -4,12 +4,12 @@ import ca.uhn.fhir.context.support.IValidationSupport; import ca.uhn.fhir.context.support.ValidationSupportContext; import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.jpa.entity.TermConcept; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; import ca.uhn.fhir.jpa.term.api.ITermDeferredStorageSvc; import ca.uhn.fhir.jpa.term.custom.CustomTerminologySet; +import ca.uhn.fhir.jpa.test.BaseJpaR4Test; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.rest.param.UriParam; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java index 94604d8fa90..9519c226e5c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplCurrentVersionR4Test.java @@ -35,13 +35,12 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; -import org.springframework.util.ResourceUtils; +import org.springframework.core.io.ClassPathResource; import javax.persistence.EntityManager; import javax.servlet.http.HttpServletResponse; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; +import java.io.InputStream; import java.util.ArrayList; import java.util.Collection; import java.util.Collections; @@ -150,9 +149,9 @@ public class TerminologySvcImplCurrentVersionR4Test extends BaseJpaR4Test { @BeforeEach public void beforeEach() throws Exception { - File file = ResourceUtils.getFile("classpath:loinc-ver/" + LOINC_UPLOAD_PROPERTIES_FILE.getCode()); + InputStream is = new ClassPathResource("loinc-ver/" + LOINC_UPLOAD_PROPERTIES_FILE.getCode()).getInputStream(); uploadProperties = new Properties(); - uploadProperties.load(new FileInputStream(file)); + uploadProperties.load(is); myValueSetIFhirResourceDao = myDaoRegistry.getResourceDao(ValueSet.class); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/TerminologySvcImplR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java similarity index 96% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java index 9125794edd7..96cbfc89c49 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ValueSetExpansionR4Test.java @@ -20,6 +20,7 @@ import ca.uhn.fhir.jpa.util.ValueSetTestUtil; import ca.uhn.fhir.rest.server.exceptions.InternalErrorException; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import com.google.common.collect.Lists; +import org.hamcrest.MatcherAssert; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.CodeSystem; import org.hl7.fhir.r4.model.CodeType; @@ -30,6 +31,7 @@ import org.hl7.fhir.r4.model.UriType; import org.hl7.fhir.r4.model.ValueSet; import org.hl7.fhir.r4.model.codesystems.HttpVerb; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.mockito.Mock; import org.slf4j.Logger; @@ -184,7 +186,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertThat(ValueSetTestUtil.toCodes(expandedValueSet).toString(), ValueSetTestUtil.toCodes(expandedValueSet), containsInAnyOrder( "code9", "code90", "code91", "code92", "code93", "code94", "code95", "code96", "code97", "code98", "code99" )); - assertEquals(11, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); + Assertions.assertEquals(11, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); assertEquals(11, expandedValueSet.getExpansion().getTotal()); // Make sure we used the pre-expanded version @@ -272,7 +274,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { //Ensure that the subsequent expansion with offset returns the same slice we are anticipating. assertThat(ValueSetTestUtil.toCodes(expandedValueSet).toString(), ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(offset, offset + count)))); - assertEquals(4, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); + Assertions.assertEquals(4, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); assertEquals(11, expandedValueSet.getExpansion().getTotal()); // Make sure we used the pre-expanded version @@ -336,7 +338,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertThat(ValueSetTestUtil.toCodes(expandedValueSet).toString(), ValueSetTestUtil.toCodes(expandedValueSet), containsInAnyOrder( "code9", "code91", "code92", "code93", "code94", "code95", "code96", "code97", "code98", "code99" )); - assertEquals(10, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); + Assertions.assertEquals(10, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); assertEquals(10, expandedValueSet.getExpansion().getTotal()); // Make sure we used the pre-expanded version @@ -435,8 +437,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertThat(ValueSetTestUtil.toCodes(expandedValueSet).toString(), ValueSetTestUtil.toCodes(expandedValueSet), containsInAnyOrder( "code9", "code90", "code91", "code92", "code93", "code94", "code95", "code96", "code97", "code98", "code99" )); - assertEquals(11, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); - assertEquals(11, expandedValueSet.getExpansion().getTotal(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); + Assertions.assertEquals(11, expandedValueSet.getExpansion().getContains().size(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); + Assertions.assertEquals(11, expandedValueSet.getExpansion().getTotal(), ValueSetTestUtil.toCodes(expandedValueSet).toString()); // Make sure we used the pre-expanded version List selectQueries = myCaptureQueriesListener.getSelectQueries(); @@ -449,8 +451,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Expand ValueSet expansion = myTermSvc.expandValueSet(new ValueSetExpansionOptions(), "http://hl7.org/fhir/ValueSet/administrative-gender"); - assertThat(ValueSetTestUtil.toCodes(expansion), containsInAnyOrder("male", "female", "other", "unknown")); - assertEquals("ValueSet with URL \"ValueSet.url[http://hl7.org/fhir/ValueSet/administrative-gender]\" was expanded using an in-memory expansion", ValueSetTestUtil.extractExpansionMessage(expansion)); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), containsInAnyOrder("male", "female", "other", "unknown")); + Assertions.assertEquals("ValueSet with URL \"ValueSet.url[http://hl7.org/fhir/ValueSet/administrative-gender]\" was expanded using an in-memory expansion", ValueSetTestUtil.extractExpansionMessage(expansion)); // Validate Code - Good String codeSystemUrl = "http://hl7.org/fhir/administrative-gender"; @@ -667,7 +669,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertConceptContainsDesignation(concept, "nl", "http://snomed.info/sct", "900000000000013009", "Synonym", "Systolische bloeddruk - expiratie"); //It is enough to test that the sublist returned is the correct one. - assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(0, 23)))); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(0, 23)))); } @Test @@ -702,7 +704,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertEquals(23, expandedValueSet.getExpansion().getContains().size()); //It is enough to test that the sublist returned is the correct one. - assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(0, 23)))); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(0, 23)))); } @Test @@ -845,7 +847,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertEquals(1000, expandedValueSet.getExpansion().getParameter().get(1).getValueIntegerType().getValue().intValue()); assertEquals(codeSystem.getConcept().size() - expandedValueSet.getExpansion().getOffset(), expandedValueSet.getExpansion().getContains().size()); - assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConcepts.subList(1, expandedConcepts.size())))); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConcepts.subList(1, expandedConcepts.size())))); } @Test @@ -877,7 +879,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertEquals(1000, expandedValueSet.getExpansion().getParameter().get(1).getValueIntegerType().getValue().intValue()); assertEquals(codeSystem.getConcept().size() - expandedValueSet.getExpansion().getOffset(), expandedValueSet.getExpansion().getContains().size()); - assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConcepts.subList(1, expandedConcepts.size())))); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConcepts.subList(1, expandedConcepts.size())))); } @Test @@ -913,7 +915,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertEquals(22, expandedValueSet.getExpansion().getContains().size()); //It is enough to test that the sublist returned is the correct one. - assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(1, 23)))); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(1, 23)))); } @Test @@ -1009,7 +1011,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { assertEquals(22, expandedValueSet.getExpansion().getContains().size()); //It is enough to test that the sublist returned is the correct one. - assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(1, 23)))); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expandedValueSet), is(equalTo(expandedConceptCodes.subList(1, 23)))); } @@ -1569,8 +1571,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Expand VS expansion = myValueSetDao.expand(vsId, new ValueSetExpansionOptions(), mySrd); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("Current status: NOT_EXPANDED")); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("28571000087109")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("Current status: NOT_EXPANDED")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("28571000087109")); // Validate code - good codeSystemUrl = "http://snomed.info/sct"; @@ -1694,9 +1696,9 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // In memory expansion ValueSet expansion = myValueSetDao.expand(vs, new ValueSetExpansionOptions()); ourLog.info(myFhirContext.newJsonParser().setPrettyPrint(true).encodeResourceToString(expansion)); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("has not yet been pre-expanded")); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("Current status: NOT_EXPANDED")); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("28571000087109")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("has not yet been pre-expanded")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("Current status: NOT_EXPANDED")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("28571000087109")); codeSystemUrl = "http://snomed.info/sct"; valueSetUrl = "http://ehealthontario.ca/fhir/ValueSet/vaccinecode"; @@ -1717,8 +1719,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Try expansion again expansion = myValueSetDao.expand(vs, new ValueSetExpansionOptions()); ourLog.info(myFhirContext.newJsonParser().setPrettyPrint(true).encodeResourceToString(expansion)); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("ValueSet was expanded using an expansion that was pre-calculated")); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("28571000087109")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("ValueSet was expanded using an expansion that was pre-calculated")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("28571000087109")); } @Test @@ -1959,8 +1961,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Expand ValueSet expansion = myValueSetDao.expand(new IdType("ValueSet/vs"), new ValueSetExpansionOptions(), mySrd); ourLog.info(myFhirContext.newJsonParser().setPrettyPrint(true).encodeResourceToString(expansion)); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("ValueSet was expanded using an expansion that was pre-calculated")); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("A")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("ValueSet was expanded using an expansion that was pre-calculated")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("A")); // Change the CodeSystem cs.getConcept().clear(); @@ -1969,7 +1971,7 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Previous precalculated expansion should still hold expansion = myValueSetDao.expand(new IdType("ValueSet/vs"), new ValueSetExpansionOptions(), mySrd); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("A")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("A")); // Invalidate the precalculated expansion myTermSvc.invalidatePreCalculatedExpansion(new IdType("ValueSet/vs"), mySrd); @@ -1977,8 +1979,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Expand (should not use a precalculated expansion) expansion = myValueSetDao.expand(new IdType("ValueSet/vs"), new ValueSetExpansionOptions(), mySrd); ourLog.info(myFhirContext.newJsonParser().setPrettyPrint(true).encodeResourceToString(expansion)); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("Performing in-memory expansion without parameters")); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("B")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("Performing in-memory expansion without parameters")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("B")); runInTransaction(()->{ List statuses = myTermValueSetDao @@ -2009,8 +2011,8 @@ public class ValueSetExpansionR4Test extends BaseTermR4Test { // Expand (should use the new precalculated expansion) expansion = myValueSetDao.expand(new IdType("ValueSet/vs"), new ValueSetExpansionOptions(), mySrd); ourLog.info(myFhirContext.newJsonParser().setPrettyPrint(true).encodeResourceToString(expansion)); - assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("ValueSet was expanded using an expansion that was pre-calculated")); - assertThat(ValueSetTestUtil.toCodes(expansion), contains("B")); + MatcherAssert.assertThat(ValueSetTestUtil.extractExpansionMessage(expansion), containsString("ValueSet was expanded using an expansion that was pre-calculated")); + MatcherAssert.assertThat(ValueSetTestUtil.toCodes(expansion), contains("B")); // Validate code that is good IValidationSupport.CodeValidationResult outcome = myValueSetDao.validateCode(vs.getUrlElement(), null, new StringType("B"), cs.getUrlElement(), null, null, null, mySrd); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ValueSetHSearchExpansionR4LuceneIT.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ValueSetHSearchExpansionR4LuceneIT.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ValueSetHSearchExpansionR4LuceneIT.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/ValueSetHSearchExpansionR4LuceneIT.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/hsearch/ReindexTerminologyHSearchR4Test.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/hsearch/ReindexTerminologyHSearchR4Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/hsearch/ReindexTerminologyHSearchR4Test.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/hsearch/ReindexTerminologyHSearchR4Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java index b96f739171c..ef18d94e8f3 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemDeleteJobTest.java @@ -39,11 +39,10 @@ import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.ValueSet; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.util.ResourceUtils; +import org.springframework.core.io.ClassPathResource; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; +import java.io.InputStream; import java.util.Properties; import static ca.uhn.fhir.jpa.batch.config.BatchConstants.TERM_CODE_SYSTEM_DELETE_JOB_NAME; @@ -95,9 +94,9 @@ public class TermCodeSystemDeleteJobTest extends BaseJpaR4Test { private IJobCoordinator myJobCoordinator; private void initMultipleVersionLoad() throws Exception { - File file = ResourceUtils.getFile("classpath:loinc-ver/" + LOINC_UPLOAD_PROPERTIES_FILE.getCode()); + InputStream is = new ClassPathResource("loinc-ver/" + LOINC_UPLOAD_PROPERTIES_FILE.getCode()).getInputStream(); uploadProperties = new Properties(); - uploadProperties.load(new FileInputStream(file)); + uploadProperties.load(is); IFhirResourceDao valueSetIFhirResourceDao = myDaoRegistry.getResourceDao(ValueSet.class); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java similarity index 97% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java index afacae7dcd6..1d57fe3639c 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/job/TermCodeSystemVersionDeleteJobTest.java @@ -41,11 +41,10 @@ import org.hl7.fhir.r4.model.ValueSet; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.util.ResourceUtils; +import org.springframework.core.io.ClassPathResource; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; +import java.io.InputStream; import java.util.Properties; import static ca.uhn.fhir.jpa.batch.config.BatchConstants.TERM_CODE_SYSTEM_VERSION_DELETE_JOB_NAME; @@ -93,9 +92,9 @@ public class TermCodeSystemVersionDeleteJobTest extends BaseJpaR4Test { private IJobCoordinator myJobCoordinator; private void initMultipleVersionLoad() throws Exception { - File file = ResourceUtils.getFile("classpath:loinc-ver/" + LOINC_UPLOAD_PROPERTIES_FILE.getCode()); + InputStream is = new ClassPathResource("loinc-ver/" + LOINC_UPLOAD_PROPERTIES_FILE.getCode()).getInputStream(); uploadProperties = new Properties(); - uploadProperties.load(new FileInputStream(file)); + uploadProperties.load(is); IFhirResourceDao valueSetIFhirResourceDao = myDaoRegistry.getResourceDao(ValueSet.class); } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/loinc/BaseLoincHandlerTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/loinc/BaseLoincHandlerTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/loinc/BaseLoincHandlerTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/term/loinc/BaseLoincHandlerTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/ValueSetTestUtil.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/util/ValueSetTestUtil.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/ValueSetTestUtil.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/util/ValueSetTestUtil.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java rename to hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java index 5525a5730df..35f9503660a 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java +++ b/hapi-fhir-jpaserver-test-r4/src/test/java/ca/uhn/fhir/jpa/util/jsonpatch/JsonPatchUtilsTest.java @@ -2,8 +2,8 @@ package ca.uhn.fhir.jpa.util.jsonpatch; import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.i18n.Msg; -import ca.uhn.fhir.jpa.test.BaseJpaTest; import ca.uhn.fhir.jpa.patch.JsonPatchUtils; +import ca.uhn.fhir.jpa.test.BaseJpaTest; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import org.hl7.fhir.r4.model.Observation; import org.junit.jupiter.api.Test; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3-person.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/dstu3-person.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3-person.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/dstu3-person.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/duplicate-conditional-create.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/duplicate-conditional-create.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/duplicate-conditional-create.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/duplicate-conditional-create.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/imgthla/bogus.txt b/hapi-fhir-jpaserver-test-r4/src/test/resources/imgthla/bogus.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/imgthla/bogus.txt rename to hapi-fhir-jpaserver-test-r4/src/test/resources/imgthla/bogus.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/imgthla/hla.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/imgthla/hla.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/imgthla/hla.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/imgthla/hla.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/imgthla/hla_nom.txt b/hapi-fhir-jpaserver-test-r4/src/test/resources/imgthla/hla_nom.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/imgthla/hla_nom.txt rename to hapi-fhir-jpaserver-test-r4/src/test/resources/imgthla/hla_nom.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/ValueSetV.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/ValueSetV.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/ValueSetV.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/ValueSetV.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/ValueSetV1.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/ValueSetV1.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/ValueSetV1.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/ValueSetV1.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/concepts.csv b/hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/concepts.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/concepts.csv rename to hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/concepts.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/hierarchy.csv b/hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/hierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/hierarchy.csv rename to hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/hierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/observation-matching.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/observation-matching.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/observation-matching.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/observation-matching.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/observation-non-matching.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/observation-non-matching.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/largecodesystem/observation-non-matching.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/largecodesystem/observation-non-matching.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-reindex/Loinc_small_v68.zip b/hapi-fhir-jpaserver-test-r4/src/test/resources/loinc-reindex/Loinc_small_v68.zip similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-reindex/Loinc_small_v68.zip rename to hapi-fhir-jpaserver-test-r4/src/test/resources/loinc-reindex/Loinc_small_v68.zip diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-reindex/v268_loincupload.properties b/hapi-fhir-jpaserver-test-r4/src/test/resources/loinc-reindex/v268_loincupload.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-reindex/v268_loincupload.properties rename to hapi-fhir-jpaserver-test-r4/src/test/resources/loinc-reindex/v268_loincupload.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/npe-causing-bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/npe-causing-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/npe-causing-bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/npe-causing-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/de.basisprofil.r4-1.2.0.tgz b/hapi-fhir-jpaserver-test-r4/src/test/resources/packages/de.basisprofil.r4-1.2.0.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/de.basisprofil.r4-1.2.0.tgz rename to hapi-fhir-jpaserver-test-r4/src/test/resources/packages/de.basisprofil.r4-1.2.0.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/CodeSystem-iar-chymh-cb-calculated-cap-10.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/CodeSystem-iar-chymh-cb-calculated-cap-10.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/CodeSystem-iar-chymh-cb-calculated-cap-10.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/CodeSystem-iar-chymh-cb-calculated-cap-10.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/ConceptMap-icd-sct.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/ConceptMap-icd-sct.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/ConceptMap-icd-sct.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/ConceptMap-icd-sct.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/StructureDefinition-kfdrc-patient-no-phi.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/StructureDefinition-kfdrc-patient-no-phi.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/StructureDefinition-kfdrc-patient-no-phi.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/StructureDefinition-kfdrc-patient-no-phi.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/StructureDefinition-kfdrc-patient.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/StructureDefinition-kfdrc-patient.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/StructureDefinition-kfdrc-patient.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/StructureDefinition-kfdrc-patient.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/ValueSet-iar-chymh-cb-calculated-cap-10.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/ValueSet-iar-chymh-cb-calculated-cap-10.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/ValueSet-iar-chymh-cb-calculated-cap-10.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/ValueSet-iar-chymh-cb-calculated-cap-10.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-cs.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-cs.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-cs.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-cs.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-ptbundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-ptbundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-ptbundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-ptbundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-vs.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-vs.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-vs.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-vs.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-vs2.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-vs2.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/adi-vs2.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/adi-vs2.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/batch-error.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/batch-error.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/batch-error.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/batch-error.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-code-in-valueset.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-code-in-valueset.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-code-in-valueset.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-code-in-valueset.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-code-not-in-valueset.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-code-not-in-valueset.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-code-not-in-valueset.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-code-not-in-valueset.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-value-is-not-quantity.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-value-is-not-quantity.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-value-is-not-quantity.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-value-is-not-quantity.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-value-is-not-quantity2.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-value-is-not-quantity2.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-obs-value-is-not-quantity2.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-obs-value-is-not-quantity2.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-sd.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-sd.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-sd.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-sd.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-vs.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-vs.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bl/bb-vs.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bl/bb-vs.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug-410-bundle.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug-410-bundle.xml similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug-410-bundle.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug-410-bundle.xml index 327367dc9a8..568cff0f9e9 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug-410-bundle.xml +++ b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug-410-bundle.xml @@ -1,4 +1,4 @@ - + @@ -101,7 +101,6 @@ - @@ -466,4 +465,4 @@ - \ No newline at end of file + diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug147-bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug147-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug147-bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug147-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug801.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug801.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug801.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug801.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug832-korean-text.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug832-korean-text.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bug832-korean-text.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bug832-korean-text.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bundle.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bundle.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/bundle.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/bundle.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/code-in-unknown-system-with-required-binding.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/code-in-unknown-system-with-required-binding.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/code-in-unknown-system-with-required-binding.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/code-in-unknown-system-with-required-binding.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/codesystem_complete.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/codesystem_complete.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/codesystem_complete.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/codesystem_complete.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/collection-bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/collection-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/collection-bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/collection-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/conceptmap.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/conceptmap.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/conceptmap.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/conceptmap.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/createdeletebundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/createdeletebundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/createdeletebundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/createdeletebundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/custom_resource_patient.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/custom_resource_patient.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/custom_resource_patient.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/custom_resource_patient.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/document-bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/document-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/document-bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/document-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/document-father.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/document-father.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/document-father.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/document-father.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/documentmanifest.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/documentmanifest.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/documentmanifest.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/documentmanifest.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/documentreference.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/documentreference.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/documentreference.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/documentreference.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/eob-bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/eob-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/eob-bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/eob-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/fragment/codesystem.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/fragment/codesystem.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/fragment/codesystem.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/fragment/codesystem.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/fragment/structuredefinition.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/fragment/structuredefinition.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/fragment/structuredefinition.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/fragment/structuredefinition.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/fragment/valueset.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/fragment/valueset.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/fragment/valueset.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/fragment/valueset.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/iar/CodeSystem-iar-citizenship-status.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/iar/CodeSystem-iar-citizenship-status.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/iar/CodeSystem-iar-citizenship-status.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/iar/CodeSystem-iar-citizenship-status.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/iar/ValueSet-iar-citizenship-status.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/iar/ValueSet-iar-citizenship-status.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/iar/ValueSet-iar-citizenship-status.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/iar/ValueSet-iar-citizenship-status.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/identical-tags-batch.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/identical-tags-batch.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/identical-tags-batch.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/identical-tags-batch.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/imagingstudy.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/imagingstudy.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/imagingstudy.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/imagingstudy.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/impact-sp.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/impact-sp.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/impact-sp.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/impact-sp.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/large-transaction.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/large-transaction.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/large-transaction.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/large-transaction.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/load_bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/load_bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/load_bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/load_bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/oruBundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/oruBundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/oruBundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/oruBundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/post1.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/post1.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/post1.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/post1.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/post2.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/post2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/post2.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/post2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/preexisting-patient.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/preexisting-patient.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/preexisting-patient.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/preexisting-patient.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/profile-differential-patient-r4.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/profile-differential-patient-r4.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/profile-differential-patient-r4.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/profile-differential-patient-r4.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/profile-vitalsigns-all-loinc.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/profile-vitalsigns-all-loinc.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/profile-vitalsigns-all-loinc.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/profile-vitalsigns-all-loinc.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/r4-create-structuredefinition-vital-signs.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/r4-create-structuredefinition-vital-signs.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/r4-create-structuredefinition-vital-signs.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/r4-create-structuredefinition-vital-signs.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/r4_transaction2.xml b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/r4_transaction2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/r4_transaction2.xml rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/r4_transaction2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/sd-david-dhtest7.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/sd-david-dhtest7.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/sd-david-dhtest7.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/sd-david-dhtest7.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/tls_communication_bug_communication.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/tls_communication_bug_communication.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/tls_communication_bug_communication.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/tls_communication_bug_communication.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-no-contained-2.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-no-contained-2.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-no-contained-2.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-no-contained-2.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-no-contained.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-no-contained.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-no-contained.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-no-contained.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-perf-bundle-smallchanges.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-perf-bundle-smallchanges.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-perf-bundle-smallchanges.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-perf-bundle-smallchanges.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-perf-bundle.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-perf-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/transaction-perf-bundle.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/transaction-perf-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/CodeSystem-cdcrec.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/CodeSystem-cdcrec.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/CodeSystem-cdcrec.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/CodeSystem-cdcrec.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/CodeSystem-dummy-loinc.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/CodeSystem-dummy-loinc.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/CodeSystem-dummy-loinc.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/CodeSystem-dummy-loinc.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-birthsex.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-birthsex.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-birthsex.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-birthsex.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-ethnicity.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-ethnicity.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-ethnicity.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-ethnicity.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-observation-lab.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-observation-lab.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-observation-lab.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-observation-lab.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-patient.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-patient.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-patient.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-patient.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-pulse-oximetry.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-pulse-oximetry.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-pulse-oximetry.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-pulse-oximetry.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-race.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-race.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/StructureDefinition-us-core-race.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/StructureDefinition-us-core-race.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-birthsex.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-birthsex.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-birthsex.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-birthsex.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-detailed-ethnicity.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-detailed-ethnicity.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-detailed-ethnicity.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-detailed-ethnicity.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-detailed-race.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-detailed-race.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-detailed-race.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-detailed-race.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-omb-ethnicity-category.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-omb-ethnicity-category.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-omb-ethnicity-category.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-omb-ethnicity-category.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-omb-race-category.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-omb-race-category.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-omb-race-category.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-omb-race-category.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-us-core-usps-state.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-us-core-usps-state.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/ValueSet-us-core-usps-state.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/ValueSet-us-core-usps-state.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/observation-pulseox.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/observation-pulseox.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/observation-pulseox.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/observation-pulseox.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/observation-resource-good.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/observation-resource-good.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/observation-resource-good.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/observation-resource-good.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/patient-resource-badcode.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/patient-resource-badcode.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/patient-resource-badcode.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/patient-resource-badcode.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/patient-resource-good.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/patient-resource-good.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/uscore/patient-resource-good.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/r4/uscore/patient-resource-good.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/term-delta-json.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/term-delta-json.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/term-delta-json.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/term-delta-json.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction-bundles/transaction-with-full-request-url.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/transaction-bundles/transaction-with-full-request-url.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction-bundles/transaction-with-full-request-url.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/transaction-bundles/transaction-with-full-request-url.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction-bundles/transaction-with-preceding-slash-request-url.json b/hapi-fhir-jpaserver-test-r4/src/test/resources/transaction-bundles/transaction-with-preceding-slash-request-url.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction-bundles/transaction-with-preceding-slash-request-url.json rename to hapi-fhir-jpaserver-test-r4/src/test/resources/transaction-bundles/transaction-with-preceding-slash-request-url.json diff --git a/hapi-fhir-jpaserver-test-r5/pom.xml b/hapi-fhir-jpaserver-test-r5/pom.xml new file mode 100644 index 00000000000..4f71ca98684 --- /dev/null +++ b/hapi-fhir-jpaserver-test-r5/pom.xml @@ -0,0 +1,113 @@ + + + 4.0.0 + + ca.uhn.hapi.fhir + hapi-deployable-pom + 6.2.0-PRE2-SNAPSHOT + ../hapi-deployable-pom/pom.xml + + + jar + + HAPI FHIR JPA Server Test R5 + hapi-fhir-jpaserver-test-r5 + + + ca.uhn.hapi.fhir + hapi-fhir-jpaserver-test-utilities + ${project.version} + test + + + + + + + org.apache.maven.plugins + maven-failsafe-plugin + + + 1 + false + alphabetical + + **/*IT.java + + false + + + + + integration-test + verify + + + + + + org.junit.jupiter + junit-jupiter-engine + ${junit_version} + + + + + org.apache.maven.plugins + maven-surefire-plugin + + alphabetical + @{argLine} ${surefire_jvm_args} + 0.6C + *StressTest* + ${skipFailsafe} + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + true + + + + + + + + NOPARALLEL + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + + **/stresstest/* + + + + + + + + CI + + + + org.apache.maven.plugins + maven-surefire-plugin + + 1 + alphabetical + + + + + + + + diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/BaseJpaR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/BaseJpaR5Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/BaseJpaR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/BaseJpaR5Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5CodeSystemTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5CodeSystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5CodeSystemTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5CodeSystemTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5SearchNoFtTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5SearchNoFtTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5SearchNoFtTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5SearchNoFtTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetMultiVersionTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetMultiVersionTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetMultiVersionTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetMultiVersionTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/FhirResourceDaoR5ValueSetTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java similarity index 64% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java index 4736bcba52d..cf6b66f952b 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/SearchParamExtractorR5Test.java @@ -1,25 +1,12 @@ package ca.uhn.fhir.jpa.dao.r5; import ca.uhn.fhir.context.FhirContext; -import ca.uhn.fhir.context.RuntimeSearchParam; import ca.uhn.fhir.jpa.model.config.PartitionSettings; -import ca.uhn.fhir.jpa.model.entity.BaseResourceIndexedSearchParam; import ca.uhn.fhir.jpa.model.entity.ModelConfig; -import ca.uhn.fhir.jpa.model.entity.NormalizedQuantitySearchLevel; import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamDate; -import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamQuantity; -import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamQuantityNormalized; -import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamString; -import ca.uhn.fhir.jpa.model.entity.ResourceIndexedSearchParamToken; -import ca.uhn.fhir.jpa.model.util.UcumServiceUtil; import ca.uhn.fhir.jpa.searchparam.extractor.ISearchParamExtractor; -import ca.uhn.fhir.jpa.searchparam.extractor.PathAndRef; -import ca.uhn.fhir.jpa.searchparam.extractor.SearchParamExtractorR4; import ca.uhn.fhir.jpa.searchparam.extractor.SearchParamExtractorR5; -import ca.uhn.fhir.rest.api.RestSearchParameterTypeEnum; import ca.uhn.fhir.rest.server.util.FhirContextSearchParamRegistry; -import ca.uhn.fhir.util.HapiExtensions; -import com.google.common.collect.Sets; import org.hl7.fhir.r5.model.Appointment; import org.hl7.fhir.r5.model.Enumerations; import org.junit.jupiter.api.BeforeEach; @@ -27,19 +14,10 @@ import org.junit.jupiter.api.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import java.util.Arrays; import java.util.Collections; import java.util.Date; -import java.util.HashSet; -import java.util.List; -import java.util.Set; -import java.util.stream.Collectors; -import static java.util.Comparator.comparing; -import static org.hamcrest.MatcherAssert.assertThat; -import static org.hamcrest.Matchers.containsInAnyOrder; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNotNull; public class SearchParamExtractorR5Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java index 84a4273e3fb..217987de64f 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/dao/r5/StorageInterceptorEventsR5Test.java @@ -6,14 +6,12 @@ import ca.uhn.fhir.jpa.api.model.ExpungeOptions; import ca.uhn.fhir.jpa.search.DatabaseBackedPagingProvider; import ca.uhn.fhir.jpa.search.PersistedJpaBundleProvider; import ca.uhn.fhir.jpa.searchparam.SearchParameterMap; -import ca.uhn.fhir.jpa.util.TestUtil; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.rest.api.server.IPreResourceShowDetails; import ca.uhn.fhir.rest.server.SimpleBundleProvider; import org.hl7.fhir.instance.model.api.IBaseResource; import org.hl7.fhir.r5.model.IdType; import org.hl7.fhir.r5.model.Patient; -import org.junit.jupiter.api.AfterAll; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java similarity index 98% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java index 7976407eab1..4eeb4cff4ce 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/AuthorizationInterceptorJpaR5Test.java @@ -13,8 +13,6 @@ import org.hl7.fhir.r5.model.Observation; import org.hl7.fhir.r5.model.Patient; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; import java.util.List; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java index a26b4775638..c1cd2a61b04 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/BaseResourceProviderR5Test.java @@ -34,8 +34,8 @@ import org.hl7.fhir.r5.model.Bundle.BundleEntryComponent; import org.hl7.fhir.r5.model.Parameters; import org.hl7.fhir.r5.model.Parameters.ParametersParameterComponent; import org.hl7.fhir.r5.model.Patient; -import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.AfterAll; +import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.context.ContextLoader; @@ -52,7 +52,6 @@ import java.util.List; import java.util.concurrent.TimeUnit; import static org.apache.commons.lang3.StringUtils.isNotBlank; -import static org.junit.jupiter.api.Assertions.fail; public abstract class BaseResourceProviderR5Test extends BaseJpaR5Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java index 8d731986ada..dfe3f2f72ea 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemDesignationTest.java @@ -1,12 +1,5 @@ package ca.uhn.fhir.jpa.provider.r5; -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNull; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - import org.hl7.fhir.r5.model.BooleanType; import org.hl7.fhir.r5.model.CodeSystem; import org.hl7.fhir.r5.model.CodeType; @@ -18,6 +11,13 @@ import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.springframework.transaction.annotation.Transactional; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertNull; + public class ResourceProviderR5CodeSystemDesignationTest extends BaseResourceProviderR5Test { private static final org.slf4j.Logger ourLog = org.slf4j.LoggerFactory.getLogger(ResourceProviderR5CodeSystemDesignationTest.class); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java index b202263d9c9..de8863c6909 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemTest.java @@ -1,19 +1,16 @@ package ca.uhn.fhir.jpa.provider.r5; -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.model.util.JpaConstants; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r4.model.codesystems.ConceptSubsumptionOutcome; -import org.hl7.fhir.r5.model.Enumerations; -import org.hl7.fhir.r5.model.Coding; import org.hl7.fhir.r5.model.BooleanType; import org.hl7.fhir.r5.model.CodeSystem; import org.hl7.fhir.r5.model.CodeSystem.ConceptDefinitionComponent; import org.hl7.fhir.r5.model.CodeType; +import org.hl7.fhir.r5.model.Coding; +import org.hl7.fhir.r5.model.Enumerations; import org.hl7.fhir.r5.model.Parameters; import org.hl7.fhir.r5.model.StringType; import org.hl7.fhir.r5.model.UriType; @@ -25,6 +22,9 @@ import org.springframework.transaction.annotation.Transactional; import java.io.IOException; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + public class ResourceProviderR5CodeSystemTest extends BaseResourceProviderR5Test { private static final String SYSTEM_PARENTCHILD = "http://parentchild"; private static final Logger ourLog = LoggerFactory.getLogger(ResourceProviderR5CodeSystemTest.class); diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java index 1865afef765..7241dbacec3 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5CodeSystemVersionedTest.java @@ -4,14 +4,14 @@ import ca.uhn.fhir.jpa.api.model.DaoMethodOutcome; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.model.util.JpaConstants; import org.hl7.fhir.r4.model.codesystems.ConceptSubsumptionOutcome; -import org.hl7.fhir.r5.model.CodeType; -import org.hl7.fhir.r5.model.UriType; -import org.hl7.fhir.r5.model.Enumerations; import org.hl7.fhir.r5.model.BooleanType; +import org.hl7.fhir.r5.model.CodeSystem; +import org.hl7.fhir.r5.model.CodeType; import org.hl7.fhir.r5.model.Coding; +import org.hl7.fhir.r5.model.Enumerations; import org.hl7.fhir.r5.model.Parameters; import org.hl7.fhir.r5.model.StringType; -import org.hl7.fhir.r5.model.CodeSystem; +import org.hl7.fhir.r5.model.UriType; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.slf4j.Logger; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ConceptMapTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ConceptMapTest.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ConceptMapTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ConceptMapTest.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java index 07b8ae2bd73..187be3063ae 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5Test.java @@ -1,19 +1,14 @@ package ca.uhn.fhir.jpa.provider.r5; -import static com.healthmarketscience.sqlbuilder.Conditions.not; -import static org.hamcrest.MatcherAssert.assertThat; -import static org.hamcrest.Matchers.containsInAnyOrder; -import static org.hamcrest.Matchers.containsString; -import static org.hamcrest.Matchers.hasItem; -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNotEquals; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; -import java.util.stream.Collectors; - +import ca.uhn.fhir.jpa.api.config.DaoConfig; +import ca.uhn.fhir.jpa.entity.Search; +import ca.uhn.fhir.jpa.model.search.SearchStatusEnum; +import ca.uhn.fhir.parser.StrictErrorHandler; +import ca.uhn.fhir.rest.client.interceptor.CapturingInterceptor; +import ca.uhn.fhir.rest.server.exceptions.NotImplementedOperationException; import ca.uhn.fhir.rest.server.exceptions.ResourceVersionConflictException; +import ca.uhn.fhir.util.UrlUtil; +import com.google.common.base.Charsets; import org.apache.commons.io.IOUtils; import org.apache.http.client.methods.CloseableHttpResponse; import org.apache.http.client.methods.HttpGet; @@ -24,12 +19,9 @@ import org.hamcrest.Matchers; import org.hl7.fhir.instance.model.api.IIdType; import org.hl7.fhir.r5.model.Bundle; import org.hl7.fhir.r5.model.Bundle.BundleEntryComponent; -import org.hl7.fhir.r5.model.CapabilityStatement; import org.hl7.fhir.r5.model.CodeableConcept; import org.hl7.fhir.r5.model.Condition; import org.hl7.fhir.r5.model.DateTimeType; -import org.hl7.fhir.r5.model.IdType; -import org.hl7.fhir.r5.model.Medication; import org.hl7.fhir.r5.model.MedicationRequest; import org.hl7.fhir.r5.model.Observation; import org.hl7.fhir.r5.model.Observation.ObservationComponentComponent; @@ -44,15 +36,17 @@ import org.junit.jupiter.api.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import com.google.common.base.Charsets; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import java.util.stream.Collectors; -import ca.uhn.fhir.jpa.api.config.DaoConfig; -import ca.uhn.fhir.jpa.entity.Search; -import ca.uhn.fhir.jpa.model.search.SearchStatusEnum; -import ca.uhn.fhir.parser.StrictErrorHandler; -import ca.uhn.fhir.rest.client.interceptor.CapturingInterceptor; -import ca.uhn.fhir.rest.server.exceptions.NotImplementedOperationException; -import ca.uhn.fhir.util.UrlUtil; +import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.containsInAnyOrder; +import static org.hamcrest.Matchers.containsString; +import static org.hamcrest.Matchers.hasItem; +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertNotEquals; @SuppressWarnings("Duplicates") public class ResourceProviderR5Test extends BaseResourceProviderR5Test { diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java index 946a2533565..456d7edaf2f 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetTest.java @@ -9,7 +9,6 @@ import ca.uhn.fhir.jpa.entity.TermConcept; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink.RelationshipTypeEnum; import ca.uhn.fhir.jpa.entity.TermValueSet; import ca.uhn.fhir.jpa.entity.TermValueSetConcept; -import ca.uhn.fhir.jpa.entity.TermValueSetConceptDesignation; import ca.uhn.fhir.jpa.entity.TermValueSetPreExpansionStatusEnum; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.term.api.ITermCodeSystemStorageSvc; @@ -55,13 +54,13 @@ import java.util.List; import java.util.Optional; import java.util.stream.Collectors; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_VALUE_SET; +import static ca.uhn.fhir.jpa.term.TermTestUtil.URL_MY_CODE_SYSTEM; +import static ca.uhn.fhir.jpa.term.TermTestUtil.URL_MY_VALUE_SET; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; -import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.containsStringIgnoringCase; import static org.hamcrest.Matchers.equalTo; +import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.not; import static org.hamcrest.Matchers.stringContainsInOrder; import static org.junit.jupiter.api.Assertions.assertEquals; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java similarity index 99% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java index 277db9bda92..375f620bf29 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ResourceProviderR5ValueSetVersionedTest.java @@ -1,6 +1,5 @@ package ca.uhn.fhir.jpa.provider.r5; -import ca.uhn.fhir.i18n.Msg; import ca.uhn.fhir.jpa.api.config.DaoConfig; import ca.uhn.fhir.jpa.api.dao.IFhirResourceDao; import ca.uhn.fhir.jpa.dao.data.IResourceTableDao; @@ -9,7 +8,6 @@ import ca.uhn.fhir.jpa.entity.TermConcept; import ca.uhn.fhir.jpa.entity.TermConceptParentChildLink.RelationshipTypeEnum; import ca.uhn.fhir.jpa.entity.TermValueSet; import ca.uhn.fhir.jpa.entity.TermValueSetConcept; -import ca.uhn.fhir.jpa.entity.TermValueSetConceptDesignation; import ca.uhn.fhir.jpa.entity.TermValueSetPreExpansionStatusEnum; import ca.uhn.fhir.jpa.model.entity.ResourceTable; import ca.uhn.fhir.jpa.term.api.ITermCodeSystemStorageSvc; @@ -18,6 +16,7 @@ import ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; import ca.uhn.fhir.rest.server.servlet.ServletRequestDetails; import org.hl7.fhir.instance.model.api.IIdType; +import org.hl7.fhir.r4.model.codesystems.HttpVerb; import org.hl7.fhir.r5.model.BooleanType; import org.hl7.fhir.r5.model.Bundle; import org.hl7.fhir.r5.model.CodeSystem; @@ -26,14 +25,13 @@ import org.hl7.fhir.r5.model.CodeSystem.ConceptDefinitionComponent; import org.hl7.fhir.r5.model.CodeType; import org.hl7.fhir.r5.model.CodeableConcept; import org.hl7.fhir.r5.model.Coding; +import org.hl7.fhir.r5.model.Enumerations.FilterOperator; import org.hl7.fhir.r5.model.IdType; import org.hl7.fhir.r5.model.Parameters; import org.hl7.fhir.r5.model.StringType; import org.hl7.fhir.r5.model.UriType; import org.hl7.fhir.r5.model.ValueSet; import org.hl7.fhir.r5.model.ValueSet.ConceptSetComponent; -import org.hl7.fhir.r5.model.Enumerations.FilterOperator; -import org.hl7.fhir.r4.model.codesystems.HttpVerb; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Test; import org.springframework.data.domain.PageRequest; @@ -46,8 +44,8 @@ import javax.annotation.Nonnull; import java.io.IOException; import java.util.Optional; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_CODE_SYSTEM; -import static ca.uhn.fhir.jpa.dao.r4.FhirResourceDaoR4TerminologyTest.URL_MY_VALUE_SET; +import static ca.uhn.fhir.jpa.term.TermTestUtil.URL_MY_CODE_SYSTEM; +import static ca.uhn.fhir.jpa.term.TermTestUtil.URL_MY_VALUE_SET; import static org.awaitility.Awaitility.await; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ServerR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ServerR5Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/provider/r5/ServerR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/provider/r5/ServerR5Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR5Test.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/subscription/BaseSubscriptionsR5Test.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java similarity index 75% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java rename to hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java index 8eb69cd3b96..f19b14d7c68 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java +++ b/hapi-fhir-jpaserver-test-r5/src/test/java/ca/uhn/fhir/jpa/subscription/resthook/RestHookTestR5Test.java @@ -8,6 +8,7 @@ import ca.uhn.fhir.rest.api.Constants; import ca.uhn.fhir.rest.api.MethodOutcome; import ca.uhn.fhir.rest.server.exceptions.UnprocessableEntityException; import ca.uhn.fhir.util.HapiExtensions; +import org.hamcrest.MatcherAssert; import org.hl7.fhir.instance.model.api.IBaseBundle; import org.hl7.fhir.r5.model.BooleanType; import org.hl7.fhir.r5.model.Bundle; @@ -21,6 +22,7 @@ import org.hl7.fhir.r5.model.SearchParameter; import org.hl7.fhir.r5.model.Subscription; import org.hl7.fhir.r5.model.SubscriptionTopic; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -73,9 +75,9 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); } @Test @@ -98,14 +100,14 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); int idx = 0; - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(idx)); - assertEquals("1", ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); - assertEquals("1", ourUpdatedObservations.get(idx).getMeta().getVersionId()); - assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); - assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); - assertEquals("1", ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(idx)); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getVersionId()); + Assertions.assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); + Assertions.assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); /* * Send version 2 @@ -118,14 +120,14 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); idx++; - waitForSize(0, ourCreatedObservations); - waitForSize(2, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(idx)); - assertEquals("2", ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); - assertEquals("2", ourUpdatedObservations.get(idx).getMeta().getVersionId()); - assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); - assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); - assertEquals("2", ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(idx)); + Assertions.assertEquals("2", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); + Assertions.assertEquals("2", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getVersionId()); + Assertions.assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); + Assertions.assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); + Assertions.assertEquals("2", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); } @Test @@ -156,9 +158,9 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Send the transaction mySystemDao.transaction(null, bundle); - waitForSize(1, ourUpdatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); - assertThat(ourUpdatedObservations.get(0).getSubject().getReference(), matchesPattern("Patient/[0-9]+")); + MatcherAssert.assertThat(BaseSubscriptionsR5Test.ourUpdatedObservations.get(0).getSubject().getReference(), matchesPattern("Patient/[0-9]+")); } @Test @@ -189,13 +191,13 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); int idx = 0; - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(idx)); - assertEquals("1", ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); - assertEquals("1", ourUpdatedObservations.get(idx).getMeta().getVersionId()); - assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); - assertEquals("1", ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(idx)); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getVersionId()); + Assertions.assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); /* * Send version 2 @@ -215,13 +217,13 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); idx++; - waitForSize(0, ourCreatedObservations); - waitForSize(2, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(idx)); - assertEquals("2", ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); - assertEquals("2", ourUpdatedObservations.get(idx).getMeta().getVersionId()); - assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); - assertEquals("2", ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(idx)); + Assertions.assertEquals("2", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdElement().getVersionIdPart()); + Assertions.assertEquals("2", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getVersionId()); + Assertions.assertEquals(obs.getMeta().getLastUpdatedElement().getValueAsString(), BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getMeta().getLastUpdatedElement().getValueAsString()); + Assertions.assertEquals("2", BaseSubscriptionsR5Test.ourUpdatedObservations.get(idx).getIdentifierFirstRep().getValue()); } @Test @@ -242,7 +244,7 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { myObservationDao.create(observation); } - waitForSize(100, ourUpdatedObservations); + waitForSize(100, BaseSubscriptionsR5Test.ourUpdatedObservations); } @Test @@ -274,9 +276,9 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); // Send an update with no changes obs.setId(obs.getIdElement().toUnqualifiedVersionless()); @@ -285,8 +287,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should be no further deliveries Thread.sleep(1000); waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); } @@ -307,11 +309,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { Observation observation1 = sendObservation(code, "SNOMED-CT"); waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); - IdType idElement = ourUpdatedObservations.get(0).getIdElement(); + IdType idElement = BaseSubscriptionsR5Test.ourUpdatedObservations.get(0).getIdElement(); assertEquals(observation1.getIdElement().getIdPart(), idElement.getIdPart()); // VersionId is present assertEquals(observation1.getIdElement().getVersionIdPart(), idElement.getVersionIdPart()); @@ -329,11 +331,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { Observation observation2 = sendObservation(code, "SNOMED-CT"); waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(2, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(1)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(1)); - idElement = ourUpdatedObservations.get(1).getIdElement(); + idElement = BaseSubscriptionsR5Test.ourUpdatedObservations.get(1).getIdElement(); assertEquals(observation2.getIdElement().getIdPart(), idElement.getIdPart()); // Now VersionId is stripped assertEquals(null, idElement.getVersionIdPart()); @@ -370,11 +372,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { myStoppableSubscriptionDeliveringRestHookSubscriber.unPause(); - waitForSize(0, ourCreatedObservations); - waitForSize(2, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); - Observation observation1 = ourUpdatedObservations.stream().filter(t->t.getIdElement().getVersionIdPart().equals("1")).findFirst().orElseThrow(()->new IllegalStateException()); - Observation observation2 = ourUpdatedObservations.stream().filter(t->t.getIdElement().getVersionIdPart().equals("2")).findFirst().orElseThrow(()->new IllegalStateException()); + Observation observation1 = BaseSubscriptionsR5Test.ourUpdatedObservations.stream().filter(t->t.getIdElement().getVersionIdPart().equals("1")).findFirst().orElseThrow(()->new IllegalStateException()); + Observation observation2 = BaseSubscriptionsR5Test.ourUpdatedObservations.stream().filter(t->t.getIdElement().getVersionIdPart().equals("2")).findFirst().orElseThrow(()->new IllegalStateException()); assertEquals("1", observation1.getIdElement().getVersionIdPart()); assertNull(observation1.getNoteFirstRep().getText()); @@ -418,11 +420,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { myStoppableSubscriptionDeliveringRestHookSubscriber.unPause(); - waitForSize(0, ourCreatedObservations); - waitForSize(2, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); - Observation observation1 = ourUpdatedObservations.get(0); - Observation observation2 = ourUpdatedObservations.get(1); + Observation observation1 = BaseSubscriptionsR5Test.ourUpdatedObservations.get(0); + Observation observation2 = BaseSubscriptionsR5Test.ourUpdatedObservations.get(1); assertEquals("2", observation1.getIdElement().getVersionIdPart()); assertEquals("changed", observation1.getNoteFirstRep().getText()); @@ -446,11 +448,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); - assertEquals("1", ourUpdatedObservations.get(0).getIdElement().getVersionIdPart()); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(0).getIdElement().getVersionIdPart()); Subscription subscriptionTemp = myClient.read(Subscription.class, subscription2.getId()); assertNotNull(subscriptionTemp); @@ -465,8 +467,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { waitForQueueToDrain(); // Should see two subscription notifications - waitForSize(0, ourCreatedObservations); - waitForSize(3, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(3, BaseSubscriptionsR5Test.ourUpdatedObservations); myClient.delete().resourceById(new IdType("Subscription/" + subscription2.getId())).execute(); waitForQueueToDrain(); @@ -475,8 +477,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { waitForQueueToDrain(); // Should see only one subscription notification - waitForSize(0, ourCreatedObservations); - waitForSize(4, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(4, BaseSubscriptionsR5Test.ourUpdatedObservations); Observation observation3 = myClient.read(Observation.class, observationTemp3.getId()); CodeableConcept codeableConcept = new CodeableConcept(); @@ -488,8 +490,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see no subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(4, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(4, BaseSubscriptionsR5Test.ourUpdatedObservations); Observation observation3a = myClient.read(Observation.class, observationTemp3.getId()); @@ -502,8 +504,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see only one subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(5, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(5, BaseSubscriptionsR5Test.ourUpdatedObservations); assertFalse(subscription1.getId().equals(subscription2.getId())); assertFalse(observation1.getId().isEmpty()); @@ -528,11 +530,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); - assertEquals("1", ourUpdatedObservations.get(0).getIdElement().getVersionIdPart()); + Assertions.assertEquals("1", BaseSubscriptionsR5Test.ourUpdatedObservations.get(0).getIdElement().getVersionIdPart()); Subscription subscriptionTemp = myClient.read(Subscription.class, subscription2.getId()); assertNotNull(subscriptionTemp); @@ -547,8 +549,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { waitForQueueToDrain(); // Should see two subscription notifications - waitForSize(0, ourCreatedObservations); - waitForSize(3, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(3, BaseSubscriptionsR5Test.ourUpdatedObservations); myClient.delete().resourceById(new IdType("Subscription/" + subscription2.getId())).execute(); waitForQueueToDrain(); @@ -557,8 +559,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { waitForQueueToDrain(); // Should see only one subscription notification - waitForSize(0, ourCreatedObservations); - waitForSize(4, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(4, BaseSubscriptionsR5Test.ourUpdatedObservations); Observation observation3 = myClient.read(Observation.class, observationTemp3.getId()); CodeableConcept codeableConcept = new CodeableConcept(); @@ -570,8 +572,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see no subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(4, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(4, BaseSubscriptionsR5Test.ourUpdatedObservations); Observation observation3a = myClient.read(Observation.class, observationTemp3.getId()); @@ -584,8 +586,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see only one subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(5, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(5, BaseSubscriptionsR5Test.ourUpdatedObservations); assertFalse(subscription1.getId().equals(subscription2.getId())); assertFalse(observation1.getId().isEmpty()); @@ -608,10 +610,10 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { Observation observation1 = sendObservation(code, "SNOMED-CT"); // Should see 1 subscription notification - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - waitForSize(1, ourContentTypes); - assertEquals(Constants.CT_FHIR_XML_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourContentTypes); + Assertions.assertEquals(Constants.CT_FHIR_XML_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); Subscription subscriptionTemp = myClient.read(Subscription.class, subscription2.getId()); assertNotNull(subscriptionTemp); @@ -625,8 +627,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { waitForQueueToDrain(); // Should see two subscription notifications - waitForSize(0, ourCreatedObservations); - waitForSize(3, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(3, BaseSubscriptionsR5Test.ourUpdatedObservations); myClient.delete().resourceById(new IdType("Subscription/" + subscription2.getId())).execute(); @@ -634,8 +636,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see only one subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(4, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(4, BaseSubscriptionsR5Test.ourUpdatedObservations); Observation observation3 = myClient.read(Observation.class, observationTemp3.getId()); CodeableConcept codeableConcept = new CodeableConcept(); @@ -647,8 +649,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see no subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(4, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(4, BaseSubscriptionsR5Test.ourUpdatedObservations); Observation observation3a = myClient.read(Observation.class, observationTemp3.getId()); @@ -661,8 +663,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see only one subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(5, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(5, BaseSubscriptionsR5Test.ourUpdatedObservations); assertFalse(subscription1.getId().equals(subscription2.getId())); assertFalse(observation1.getId().isEmpty()); @@ -712,11 +714,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { myClient.transaction().withBundle(requestBundle).execute(); // Should see 1 subscription notification - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_XML_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_XML_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); - Observation obs = ourUpdatedObservations.get(0); + Observation obs = BaseSubscriptionsR5Test.ourUpdatedObservations.get(0); ourLog.info("Observation content: {}", myFhirCtx.newXmlParser().setPrettyPrint(true).encodeResourceToString(obs)); } @@ -738,7 +740,7 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Criteria didn't match, shouldn't see any updates waitForQueueToDrain(); Thread.sleep(1000); - assertEquals(0, ourUpdatedObservations.size()); + Assertions.assertEquals(0, BaseSubscriptionsR5Test.ourUpdatedObservations.size()); Subscription subscriptionTemp = myClient.read().resource(Subscription.class).withId(subscription2.getId()).execute(); assertNotNull(subscriptionTemp); @@ -756,8 +758,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { waitForQueueToDrain(); // Should see a subscription notification this time - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); myClient.delete().resourceById(new IdType("Subscription/" + subscription2.getId())).execute(); @@ -765,7 +767,7 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // No more matches Thread.sleep(1000); - assertEquals(1, ourUpdatedObservations.size()); + Assertions.assertEquals(1, BaseSubscriptionsR5Test.ourUpdatedObservations.size()); } @Test @@ -784,9 +786,9 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_XML_NEW, ourContentTypes.get(0)); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_XML_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); } @Test @@ -824,11 +826,11 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); - assertEquals(Constants.CT_FHIR_JSON_NEW, ourContentTypes.get(0)); - assertThat(ourHeaders, hasItem("X-Foo: FOO")); - assertThat(ourHeaders, hasItem("X-Bar: BAR")); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); + Assertions.assertEquals(Constants.CT_FHIR_JSON_NEW, BaseSubscriptionsR5Test.ourContentTypes.get(0)); + assertThat(BaseSubscriptionsR5Test.ourHeaders, hasItem("X-Foo: FOO")); + assertThat(BaseSubscriptionsR5Test.ourHeaders, hasItem("X-Bar: BAR")); } @Test @@ -845,8 +847,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); // Disable subscription.setStatus(Enumerations.SubscriptionStatusCodes.OFF); @@ -858,8 +860,8 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { // Should see 1 subscription notification waitForQueueToDrain(); - waitForSize(0, ourCreatedObservations); - waitForSize(1, ourUpdatedObservations); + waitForSize(0, BaseSubscriptionsR5Test.ourCreatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); } @@ -958,7 +960,7 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { MethodOutcome methodOutcome = myClient.create().resource(bodySite).execute(); assertEquals(true, methodOutcome.getCreated()); waitForQueueToDrain(); - waitForSize(1, ourUpdatedObservations); + waitForSize(1, BaseSubscriptionsR5Test.ourUpdatedObservations); } { Observation observation = new Observation(); @@ -966,14 +968,14 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { MethodOutcome methodOutcome = myClient.create().resource(observation).execute(); assertEquals(true, methodOutcome.getCreated()); waitForQueueToDrain(); - waitForSize(2, ourUpdatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); } { Observation observation = new Observation(); MethodOutcome methodOutcome = myClient.create().resource(observation).execute(); assertEquals(true, methodOutcome.getCreated()); waitForQueueToDrain(); - waitForSize(2, ourUpdatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); } { Observation observation = new Observation(); @@ -981,7 +983,7 @@ public class RestHookTestR5Test extends BaseSubscriptionsR5Test { MethodOutcome methodOutcome = myClient.create().resource(observation).execute(); assertEquals(true, methodOutcome.getCreated()); waitForQueueToDrain(); - waitForSize(2, ourUpdatedObservations); + waitForSize(2, BaseSubscriptionsR5Test.ourUpdatedObservations); } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/dao/DaoTestUtils.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/dao/DaoTestUtils.java new file mode 100644 index 00000000000..41934b32c57 --- /dev/null +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/dao/DaoTestUtils.java @@ -0,0 +1,34 @@ +package ca.uhn.fhir.jpa.dao; + +import ca.uhn.fhir.i18n.Msg; +import ca.uhn.fhir.interceptor.api.IInterceptorService; +import ca.uhn.fhir.rest.server.exceptions.ResourceVersionConflictException; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.List; +import java.util.stream.Collectors; + +import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.matchesPattern; + +public final class DaoTestUtils { + private static final Logger ourLog = LoggerFactory.getLogger(DaoTestUtils.class); + + private DaoTestUtils() {} + + public static void assertConflictException(ResourceVersionConflictException e) { + assertThat(e.getMessage(), matchesPattern( + Msg.code(550) + Msg.code(515) + "Unable to delete [a-zA-Z]+/[0-9]+ because at least one resource has a reference to this resource. First reference found was resource [a-zA-Z]+/[0-9]+ in path [a-zA-Z]+.[a-zA-Z]+")); + } + + public static void logAllInterceptors(IInterceptorService theInterceptorRegistry) { + List allInterceptors = theInterceptorRegistry.getAllRegisteredInterceptors(); + String interceptorList = allInterceptors + .stream() + .map(t -> t.getClass().toString()) + .sorted() + .collect(Collectors.joining("\n * ")); + ourLog.info("Registered interceptors:\n * {}", interceptorList); + } +} diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadAllPartitions.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadAllPartitions.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadAllPartitions.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadAllPartitions.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java similarity index 91% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java index 4c6c92a5018..af4f0dc62a3 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/interceptor/ex/PartitionInterceptorReadPartitionsBasedOnScopes.java @@ -6,11 +6,8 @@ import ca.uhn.fhir.interceptor.api.Pointcut; import ca.uhn.fhir.interceptor.model.RequestPartitionId; import ca.uhn.fhir.rest.server.exceptions.InvalidRequestException; import ca.uhn.fhir.rest.server.servlet.ServletRequestDetails; -import ca.uhn.fhir.util.ValidateUtil; -import org.apache.commons.lang3.math.NumberUtils; import javax.servlet.http.HttpServletRequest; -import java.util.Optional; import java.util.Set; // This class is replicated in PartitionExamples.java -- Keep it up to date there too!! diff --git a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/packages/FakeNpmServlet.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/packages/FakeNpmServlet.java new file mode 100644 index 00000000000..5dea8f863db --- /dev/null +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/packages/FakeNpmServlet.java @@ -0,0 +1,46 @@ +package ca.uhn.fhir.jpa.packages; + +import ca.uhn.fhir.rest.api.Constants; +import org.apache.commons.lang3.StringUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +class FakeNpmServlet extends HttpServlet { + private static final Logger ourLog = LoggerFactory.getLogger(FakeNpmServlet.class); + + final Map responses = new HashMap<>(); + + @Override + protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException { + String requestUrl = req.getRequestURI(); + if (responses.containsKey(requestUrl)) { + ourLog.info("Responding to request: {}", requestUrl); + + resp.setStatus(200); + + if (StringUtils.countMatches(requestUrl, "/") == 1) { + resp.setHeader(Constants.HEADER_CONTENT_TYPE, Constants.CT_JSON); + } else { + resp.setHeader(Constants.HEADER_CONTENT_TYPE, "application/gzip"); + } + resp.getOutputStream().write(responses.get(requestUrl)); + resp.getOutputStream().close(); + } else { + ourLog.warn("Unknown request: {}", requestUrl); + + resp.sendError(404); + } + + } + + public Map getResponses() { + return responses; + } +} diff --git a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/provider/GraphQLProviderTestUtil.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/provider/GraphQLProviderTestUtil.java new file mode 100644 index 00000000000..28203e59af1 --- /dev/null +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/provider/GraphQLProviderTestUtil.java @@ -0,0 +1,6 @@ +package ca.uhn.fhir.jpa.provider; + +public class GraphQLProviderTestUtil { + public static final String DATA_PREFIX = "{\"data\": "; + public static final String DATA_SUFFIX = "}"; +} diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/CountingInterceptor.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/CountingInterceptor.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/CountingInterceptor.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/CountingInterceptor.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/NotificationServlet.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/NotificationServlet.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/NotificationServlet.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/NotificationServlet.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java similarity index 91% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java index 98474aa1760..2135e0f3c2b 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/subscription/SocketImplementation.java @@ -1,16 +1,17 @@ package ca.uhn.fhir.jpa.subscription; +import ca.uhn.fhir.rest.api.EncodingEnum; +import org.eclipse.jetty.websocket.api.Session; +import org.eclipse.jetty.websocket.api.annotations.OnWebSocketConnect; +import org.eclipse.jetty.websocket.api.annotations.OnWebSocketMessage; +import org.eclipse.jetty.websocket.api.annotations.WebSocket; +import org.slf4j.Logger; + import java.util.ArrayList; import java.util.Collections; import java.util.List; -import org.eclipse.jetty.websocket.api.Session; -import org.eclipse.jetty.websocket.api.annotations.*; -import org.slf4j.Logger; - -import ca.uhn.fhir.rest.api.EncodingEnum; - @WebSocket public class SocketImplementation { diff --git a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/term/TermTestUtil.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/term/TermTestUtil.java new file mode 100644 index 00000000000..61395e5c03a --- /dev/null +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/term/TermTestUtil.java @@ -0,0 +1,159 @@ +package ca.uhn.fhir.jpa.term; + +import ca.uhn.fhir.jpa.entity.TermConceptDesignation; +import ca.uhn.fhir.jpa.term.api.ITermLoaderSvc; + +import java.io.IOException; +import java.util.Collection; + +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_DUPLICATE_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_LINK_DUPLICATE_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_ANSWERLIST_LINK_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_CONSUMER_NAME_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_DOCUMENT_ONTOLOGY_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_DUPLICATE_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_GROUP_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_GROUP_TERMS_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_HIERARCHY_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_IEEE_MEDICAL_DEVICE_CODE_MAPPING_TABLE_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_IMAGING_DOCUMENT_CODES_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_LINGUISTIC_VARIANTS_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PARENT_GROUP_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_LINK_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_LINK_FILE_PRIMARY_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_PART_RELATED_CODE_MAPPING_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_RSNA_PLAYBOOK_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_TOP2000_COMMON_LAB_RESULTS_SI_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_TOP2000_COMMON_LAB_RESULTS_US_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_UNIVERSAL_LAB_ORDER_VALUESET_FILE_DEFAULT; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_UPLOAD_PROPERTIES_FILE; +import static ca.uhn.fhir.jpa.term.loinc.LoincUploadPropertiesEnum.LOINC_XML_FILE; +import static org.junit.jupiter.api.Assertions.assertEquals; + +public final class TermTestUtil { + public static final String URL_MY_CODE_SYSTEM = "http://example.com/my_code_system"; + public static final String URL_MY_VALUE_SET = "http://example.com/my_value_set"; + + private TermTestUtil() {} + + public static void addLoincMandatoryFilesAndSinglePartLinkToZip(ZipCollectionBuilder theFiles) throws IOException { + addBaseLoincMandatoryFilesToZip(theFiles, true); + theFiles.addFileZip("/loinc/", "loincupload_singlepartlink.properties"); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_DEFAULT.getCode()); + } + + public static void addLoincMandatoryFilesAndConsumerNameAndLinguisticVariants(ZipCollectionBuilder theFiles) throws IOException { + addBaseLoincMandatoryFilesToZip(theFiles, true); + theFiles.addFileZip("/loinc/", "loincupload_singlepartlink.properties"); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_CONSUMER_NAME_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT.getCode() + "zhCN5LinguisticVariant.csv"); + theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT.getCode() + "deAT24LinguisticVariant.csv"); + theFiles.addFileZip("/loinc/", LOINC_LINGUISTIC_VARIANTS_PATH_DEFAULT.getCode() + "frCA8LinguisticVariant.csv"); + } + + public static void addLoincMandatoryFilesToZip(ZipCollectionBuilder theFiles) throws IOException { + addBaseLoincMandatoryFilesToZip(theFiles, true); + theFiles.addFileZip("/loinc/", LOINC_UPLOAD_PROPERTIES_FILE.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_PRIMARY_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT.getCode()); + } + + public static void addLoincMandatoryFilesWithoutTop2000ToZip(ZipCollectionBuilder theFiles) throws IOException { + addBaseLoincMandatoryFilesToZip(theFiles, false); + theFiles.addFileZip("/loinc/", LOINC_UPLOAD_PROPERTIES_FILE.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_PRIMARY_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT.getCode()); + } + + public static void addLoincMandatoryFilesWithPropertiesFileToZip(ZipCollectionBuilder theFiles, String thePropertiesFile) throws IOException { + if (thePropertiesFile != null) { + theFiles.addFileZip("/loinc/", thePropertiesFile); + } + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_PRIMARY_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_LINK_FILE_SUPPLEMENTARY_DEFAULT.getCode()); + addBaseLoincMandatoryFilesToZip(theFiles, true); + } + + static void addBaseLoincMandatoryFilesToZip(ZipCollectionBuilder theFiles, Boolean theIncludeTop2000) throws IOException{ + theFiles.addFileZip("/loinc/", LOINC_XML_FILE.getCode()); + theFiles.addFileZip("/loinc/", LOINC_GROUP_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_GROUP_TERMS_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PARENT_GROUP_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_DUPLICATE_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_HIERARCHY_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_DUPLICATE_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_LINK_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_ANSWERLIST_LINK_DUPLICATE_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_PART_RELATED_CODE_MAPPING_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_DOCUMENT_ONTOLOGY_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_RSNA_PLAYBOOK_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_UNIVERSAL_LAB_ORDER_VALUESET_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_IEEE_MEDICAL_DEVICE_CODE_MAPPING_TABLE_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_IMAGING_DOCUMENT_CODES_FILE_DEFAULT.getCode()); + if (theIncludeTop2000) { + theFiles.addFileZip("/loinc/", LOINC_TOP2000_COMMON_LAB_RESULTS_SI_FILE_DEFAULT.getCode()); + theFiles.addFileZip("/loinc/", LOINC_TOP2000_COMMON_LAB_RESULTS_US_FILE_DEFAULT.getCode()); + } + + } + + static void verifyConsumerName(Collection designationList, String theConsumerName) { + + TermConceptDesignation consumerNameDesignation = null; + for (TermConceptDesignation designation : designationList) { + if ("ConsumerName".equals(designation.getUseDisplay() )) { + consumerNameDesignation = designation; + } + } + assertEquals(theConsumerName, consumerNameDesignation.getValue()); + } + + static void verifyLinguisticVariant(Collection designationList, String theLanguage, + String theComponent, String theProperty, String theTimeAspct, String theSystem, String theScaleTyp, + String methodType, String theClass, String theShortName, String theLongCommonName, String theRelatedName2, + String theLinguisticVariantDisplayName) { + + TermConceptDesignation formalNameDes = null; + TermConceptDesignation shortNameDes = null; + TermConceptDesignation longCommonNameDes = null; + TermConceptDesignation linguisticVariantDisplayNameDes = null; + + for (TermConceptDesignation designation : designationList) { + if (theLanguage.equals(designation.getLanguage())) { + + if ("FullySpecifiedName".equals(designation.getUseDisplay())) + formalNameDes = designation; + + if ("SHORTNAME".equals(designation.getUseDisplay())) + shortNameDes = designation; + if ("LONG_COMMON_NAME".equals(designation.getUseDisplay())) + longCommonNameDes = designation; + if ("LinguisticVariantDisplayName".equals(designation.getUseDisplay())) + linguisticVariantDisplayNameDes = designation; + } + } + + verifyDesignation(formalNameDes, ITermLoaderSvc.LOINC_URI, "FullySpecifiedName", theComponent+":"+theProperty+":"+theTimeAspct+":"+theSystem+":"+theScaleTyp+":"+methodType); + verifyDesignation(shortNameDes, ITermLoaderSvc.LOINC_URI, "SHORTNAME", theShortName); + verifyDesignation(longCommonNameDes, ITermLoaderSvc.LOINC_URI, "LONG_COMMON_NAME", theLongCommonName); + verifyDesignation(linguisticVariantDisplayNameDes, ITermLoaderSvc.LOINC_URI, "LinguisticVariantDisplayName", theLinguisticVariantDisplayName); + } + + private static void verifyDesignation(TermConceptDesignation theDesignation, String theUseSystem, String theUseCode, String theValue) { + if (theDesignation == null) + return; + assertEquals(theUseSystem, theDesignation.getUseSystem()); + assertEquals(theUseCode, theDesignation.getUseCode()); + assertEquals(theValue, theDesignation.getValue()); + } +} diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ZipCollectionBuilder.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/term/ZipCollectionBuilder.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/ZipCollectionBuilder.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/term/ZipCollectionBuilder.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/test/BaseJpaTest.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/test/BaseJpaTest.java index d24158088c7..73d8702e5af 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/test/BaseJpaTest.java +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/test/BaseJpaTest.java @@ -68,8 +68,6 @@ import ca.uhn.fhir.jpa.subscription.match.registry.SubscriptionLoader; import ca.uhn.fhir.jpa.subscription.match.registry.SubscriptionRegistry; import ca.uhn.fhir.jpa.util.CircularQueueCaptureQueriesListener; import ca.uhn.fhir.jpa.util.MemoryCacheService; -import ca.uhn.fhir.model.dstu2.resource.Bundle; -import ca.uhn.fhir.model.dstu2.resource.Bundle.Entry; import ca.uhn.fhir.rest.api.Constants; import ca.uhn.fhir.rest.api.server.IBundleProvider; import ca.uhn.fhir.rest.server.exceptions.InternalErrorException; @@ -554,16 +552,6 @@ public abstract class BaseJpaTest extends BaseTest { return retVal; } - protected List toUnqualifiedVersionlessIds(Bundle theFound) { - List retVal = new ArrayList<>(); - for (Entry next : theFound.getEntry()) { - // if (next.getResource()!= null) { - retVal.add(next.getResource().getId().toUnqualifiedVersionless()); - // } - } - return retVal; - } - protected List toUnqualifiedVersionlessIds(IBundleProvider theProvider) { List retVal = new ArrayList<>(); diff --git a/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/util/CoordCalculatorTestUtil.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/util/CoordCalculatorTestUtil.java new file mode 100644 index 00000000000..11a988ad003 --- /dev/null +++ b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/util/CoordCalculatorTestUtil.java @@ -0,0 +1,19 @@ +package ca.uhn.fhir.jpa.util; + +public final class CoordCalculatorTestUtil { + // CHIN and UHN coordinates from Google Maps + // Distance and bearing from https://www.movable-type.co.uk/scripts/latlong.html + public static final double LATITUDE_CHIN = 43.65513; + public static final double LONGITUDE_CHIN = -79.4170007; + public static final double LATITUDE_UHN = 43.656765; + public static final double LONGITUDE_UHN = -79.3987645; + public static final double DISTANCE_KM_CHIN_TO_UHN = 1.478; + public static final double BEARING_CHIN_TO_UHN = 82 + (55.0 / 60) + (46.0 / 3600); + // A Fiji island near the anti-meridian + public static final double LATITUDE_TAVEUNI = -16.8488893; + public static final double LONGITIDE_TAVEUNI = 179.889793; + // enough distance from point to cross anti-meridian + public static final double DISTANCE_TAVEUNI = 100.0; + + private CoordCalculatorTestUtil() {} +} diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/ForceSynchronousSearchInterceptor.java b/hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/util/ForceSynchronousSearchInterceptor.java similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/ForceSynchronousSearchInterceptor.java rename to hapi-fhir-jpaserver-test-utilities/src/main/java/ca/uhn/fhir/jpa/util/ForceSynchronousSearchInterceptor.java diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/basic-stu3.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/basic-stu3.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/basic-stu3.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/basic-stu3.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bryn-bundle.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/bryn-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bryn-bundle.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/bryn-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug454_utf8.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/bug454_utf8.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug454_utf8.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/bug454_utf8.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug872-ext-with-hl7-url.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/bug872-ext-with-hl7-url.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug872-ext-with-hl7-url.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/bug872-ext-with-hl7-url.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/bug_516_invalid_expansion.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/bug_516_invalid_expansion.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/bug_516_invalid_expansion.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/bug_516_invalid_expansion.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/cdr-bundle.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/cdr-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/cdr-bundle.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/cdr-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/codesystem.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/codesystem.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/codesystem.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/codesystem.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/concepts.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/concepts.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/concepts.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/concepts.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/hierarchy.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/hierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/hierarchy.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/hierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/properties.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/properties.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/custom_term/properties.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/custom_term/properties.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/david-bundle-error.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/david-bundle-error.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/david-bundle-error.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/david-bundle-error.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/david_big_bundle.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/david_big_bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/david_big_bundle.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/david_big_bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/documentmanifest.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/documentmanifest.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/documentmanifest.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/documentmanifest.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/documentreference.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/documentreference.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/documentreference.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/documentreference.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3-post1.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/dstu3-post1.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3-post1.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/dstu3-post1.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3-post2.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/dstu3-post2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3-post2.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/dstu3-post2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_transaction.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/dstu3_transaction.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/dstu3_transaction.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/dstu3_transaction.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-cs-with-designations-lang.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-cs-with-designations-lang.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-cs-with-designations-lang.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-cs-with-designations-lang.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-cs-with-designations.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-cs-with-designations.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-cs-with-designations.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-cs-with-designations.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-cs.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-cs.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-cs.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-cs.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-vs-with-exclude.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-vs-with-exclude.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-vs-with-exclude.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-vs-with-exclude.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-vs.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-vs.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-3-vs.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-3-vs.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-dstu3.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-dstu3.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/extensional-case-dstu3.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/extensional-case-dstu3.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/icd/icd10cm_tabular_2021.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/icd/icd10cm_tabular_2021.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/icd/icd10cm_tabular_2021.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/icd/icd10cm_tabular_2021.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/imagingstudy.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/imagingstudy.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/imagingstudy.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/imagingstudy.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/josh-bundle.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/josh-bundle.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/josh-bundle.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/josh-bundle.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/loincupload.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/loincupload.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/loincupload.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/loincupload.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/loincupload_singlepartlink.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/loincupload_singlepartlink.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/loincupload_singlepartlink.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/loincupload_singlepartlink.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/ConsumerName/ConsumerName.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/ConsumerName/ConsumerName.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/ConsumerName/ConsumerName.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/ConsumerName/ConsumerName.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/DocumentOntology/DocumentOntology.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/DocumentOntology/DocumentOntology.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/DocumentOntology/DocumentOntology.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/DocumentOntology/DocumentOntology.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/Group.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/Group.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/Group.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/Group.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/GroupLoincTerms.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/GroupLoincTerms.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/GroupLoincTerms.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/GroupLoincTerms.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/ParentGroup.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/ParentGroup.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/ParentGroup.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/GroupFile/ParentGroup.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Primary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Primary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Primary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Primary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/Part.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/Part.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/Part.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/Part.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/LoincTable/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/LoincTable/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/LoincTable/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/LoincTable/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/loinc.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/loinc.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v-no-version/loinc.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v-no-version/loinc.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/ConsumerName/ConsumerName.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/ConsumerName/ConsumerName.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/ConsumerName/ConsumerName.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/ConsumerName/ConsumerName.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/DocumentOntology/DocumentOntology.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/DocumentOntology/DocumentOntology.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/DocumentOntology/DocumentOntology.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/DocumentOntology/DocumentOntology.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/GroupFile/Group.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/GroupFile/Group.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/GroupFile/Group.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/GroupFile/Group.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/GroupFile/GroupLoincTerms.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/GroupFile/GroupLoincTerms.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/GroupFile/GroupLoincTerms.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/GroupFile/GroupLoincTerms.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/GroupFile/ParentGroup.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/GroupFile/ParentGroup.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/GroupFile/ParentGroup.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/GroupFile/ParentGroup.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Primary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Primary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Primary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Primary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/Part.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/Part.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/Part.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/Part.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/LoincTable/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/LoincTable/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/LoincTable/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/LoincTable/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/loinc.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/loinc.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v267/loinc.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v267/loinc.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/ConsumerName/ConsumerName.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/ConsumerName/ConsumerName.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/ConsumerName/ConsumerName.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/ConsumerName/ConsumerName.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/DocumentOntology/DocumentOntology.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/DocumentOntology/DocumentOntology.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/DocumentOntology/DocumentOntology.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/DocumentOntology/DocumentOntology.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/GroupFile/Group.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/GroupFile/Group.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/GroupFile/Group.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/GroupFile/Group.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/GroupFile/GroupLoincTerms.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/GroupFile/GroupLoincTerms.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/GroupFile/GroupLoincTerms.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/GroupFile/GroupLoincTerms.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/GroupFile/ParentGroup.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/GroupFile/ParentGroup.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/GroupFile/ParentGroup.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/GroupFile/ParentGroup.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Primary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Primary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Primary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Primary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/Part.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/Part.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/Part.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/Part.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/LoincTable/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/LoincTable/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/LoincTable/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/LoincTable/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/loinc.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/loinc.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v268/loinc.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v268/loinc.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/ConsumerName/ConsumerName.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/ConsumerName/ConsumerName.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/ConsumerName/ConsumerName.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/ConsumerName/ConsumerName.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/DocumentOntology/DocumentOntology.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/DocumentOntology/DocumentOntology.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/DocumentOntology/DocumentOntology.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/DocumentOntology/DocumentOntology.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/GroupFile/Group.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/GroupFile/Group.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/GroupFile/Group.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/GroupFile/Group.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/GroupFile/GroupLoincTerms.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/GroupFile/GroupLoincTerms.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/GroupFile/GroupLoincTerms.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/GroupFile/GroupLoincTerms.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/GroupFile/ParentGroup.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/GroupFile/ParentGroup.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/GroupFile/ParentGroup.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/GroupFile/ParentGroup.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Primary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Primary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Primary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Primary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/Part.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/Part.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/Part.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/Part.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/LoincTable/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/LoincTable/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/LoincTable/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/LoincTable/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/loinc.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/loinc.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc-ver/v269/loinc.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc-ver/v269/loinc.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/AnswerFile/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/AnswerFile/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/AnswerFile/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/AnswerFile/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/AnswerFile/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/ConsumerName/ConsumerName.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/ConsumerName/ConsumerName.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/ConsumerName/ConsumerName.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/ConsumerName/ConsumerName.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/DocumentOntology/DocumentOntology.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/DocumentOntology/DocumentOntology.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/DocumentOntology/DocumentOntology.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/DocumentOntology/DocumentOntology.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/GroupFile/Group.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/GroupFile/Group.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/GroupFile/Group.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/GroupFile/Group.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/GroupFile/GroupLoincTerms.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/GroupFile/GroupLoincTerms.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/GroupFile/GroupLoincTerms.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/GroupFile/GroupLoincTerms.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/GroupFile/ParentGroup.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/GroupFile/ParentGroup.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/GroupFile/ParentGroup.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/GroupFile/ParentGroup.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/ImagingDocuments/ImagingDocumentCodes.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/LinguisticVariants.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/deAT24LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/frCA8LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LinguisticVariants/zhCN5LinguisticVariant.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LoincIeeeMedicalDeviceCodeMappingTable/LoincIeeeMedicalDeviceCodeMappingTable.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LoincRsnaRadiologyPlaybook/LoincRsnaRadiologyPlaybook.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/LoincUniversalLabOrdersValueSet/LoincUniversalLabOrdersValueSet.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/MultiAxialHierarchy/MultiAxialHierarchy.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PanelsAndForms/AnswerList.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PanelsAndForms/AnswerList.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PanelsAndForms/AnswerList.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PanelsAndForms/AnswerList.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PanelsAndForms/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PanelsAndForms/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PanelsAndForms/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PanelsAndForms/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PanelsAndForms/LoincAnswerListLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/LoincPartLink.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/LoincPartLink.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/LoincPartLink.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/LoincPartLink.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Primary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Primary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Primary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Primary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/LoincPartLink_Supplementary.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/Part.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/Part.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/Part.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/Part.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/PartFile/PartRelatedCodeMapping.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/Top2000Results/SI/Top2000CommonLabResultsSi.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/AccessoryFiles/Top2000Results/US/Top2000CommonLabResultsUs.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/LoincTable/Loinc.csv b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/LoincTable/Loinc.csv similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/LoincTable/Loinc.csv rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/LoincTable/Loinc.csv diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/loinc.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/loinc.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/loinc.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/loinc.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/loincupload.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/loincupload.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/loincupload.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/loincupload.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/loincupload_singlepartlink.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/loincupload_singlepartlink.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/loincupload_singlepartlink.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/loincupload_singlepartlink.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/v267_loincupload.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/v267_loincupload.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/v267_loincupload.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/v267_loincupload.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/v268_curr_false_loincupload.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/v268_curr_false_loincupload.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/v268_curr_false_loincupload.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/v268_curr_false_loincupload.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/v268_loincupload.properties b/hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/v268_loincupload.properties similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/loinc/v268_loincupload.properties rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/loinc/v268_loincupload.properties diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/UK.Core.r4-1.1.0.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/UK.Core.r4-1.1.0.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/UK.Core.r4-1.1.0.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/UK.Core.r4-1.1.0.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/basisprofil.de.tar.gz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/basisprofil.de.tar.gz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/basisprofil.de.tar.gz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/basisprofil.de.tar.gz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/erroneous-ig.tar.gz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/erroneous-ig.tar.gz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/erroneous-ig.tar.gz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/erroneous-ig.tar.gz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.11.0.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.11.0.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.11.0.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.11.0.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.11.1.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.11.1.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.11.1.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.11.1.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.12.0.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.12.0.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.12.0.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.12.0.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.13.0.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.13.0.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/hl7.fhir.uv.shorthand-0.13.0.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/hl7.fhir.uv.shorthand-0.13.0.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.questionnaires-1.0.2.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/nictiz.fhir.nl.stu3.questionnaires-1.0.2.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/nictiz.fhir.nl.stu3.questionnaires-1.0.2.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/nictiz.fhir.nl.stu3.questionnaires-1.0.2.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/package-davinci-cdex-0.2.0.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/package-davinci-cdex-0.2.0.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/package-davinci-cdex-0.2.0.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/package-davinci-cdex-0.2.0.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-auto-create-placeholder.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-auto-create-placeholder.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-auto-create-placeholder.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-auto-create-placeholder.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-draft-sample.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-draft-sample.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-draft-sample.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-draft-sample.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-exchange-sample-2.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-exchange-sample-2.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-exchange-sample-2.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-exchange-sample-2.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-exchange-sample.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-exchange-sample.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-exchange-sample.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-exchange-sample.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-logical-structuredefinition.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-logical-structuredefinition.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-logical-structuredefinition.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-logical-structuredefinition.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-missing-identifier-package.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-missing-identifier-package.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-missing-identifier-package.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-missing-identifier-package.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-organizations-package.tgz b/hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-organizations-package.tgz similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/packages/test-organizations-package.tgz rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/packages/test-organizations-package.tgz diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/extensional-case-r4.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/r4/extensional-case-r4.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/extensional-case-r4.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/r4/extensional-case-r4.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/extensional-case.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/r4/extensional-case.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/r4/extensional-case.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/r4/extensional-case.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sample-document.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sample-document.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sample-document.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sample-document.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Concept_Full-en_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Concept_Full-en_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Concept_Full-en_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Concept_Full-en_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Concept_Full_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Concept_Full_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Concept_Full_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Concept_Full_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Description_Full-en_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Description_Full-en_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Description_Full-en_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Description_Full-en_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Identifier_Full_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Identifier_Full_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Identifier_Full_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Identifier_Full_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Relationship_Full_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Relationship_Full_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_Relationship_Full_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_Relationship_Full_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_StatedRelationship_Full_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_StatedRelationship_Full_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_StatedRelationship_Full_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_StatedRelationship_Full_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_TextDefinition_Full-en_INT_20160131.txt b/hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_TextDefinition_Full-en_INT_20160131.txt similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/sct/sct2_TextDefinition_Full-en_INT_20160131.txt rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/sct/sct2_TextDefinition_Full-en_INT_20160131.txt diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/simone-conditional-url.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/simone-conditional-url.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/simone-conditional-url.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/simone-conditional-url.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/simone_bundle.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/simone_bundle.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/simone_bundle.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/simone_bundle.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/simone_bundle2.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/simone_bundle2.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/simone_bundle2.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/simone_bundle2.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/simone_bundle3.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/simone_bundle3.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/simone_bundle3.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/simone_bundle3.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction-bundle.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/transaction-bundle.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction-bundle.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/transaction-bundle.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction_link_patient_eve.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/transaction_link_patient_eve.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction_link_patient_eve.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/transaction_link_patient_eve.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction_link_patient_eve_temp.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/transaction_link_patient_eve_temp.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/transaction_link_patient_eve_temp.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/transaction_link_patient_eve_temp.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/update.xml b/hapi-fhir-jpaserver-test-utilities/src/main/resources/update.xml similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/update.xml rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/update.xml diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/resources/valueset-dstu2.json b/hapi-fhir-jpaserver-test-utilities/src/main/resources/valueset-dstu2.json similarity index 100% rename from hapi-fhir-jpaserver-test-utilities/src/test/resources/valueset-dstu2.json rename to hapi-fhir-jpaserver-test-utilities/src/main/resources/valueset-dstu2.json diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/DynamicJobFlowSandbox.java b/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/DynamicJobFlowSandbox.java index d91962ced9d..5f21b5a31db 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/DynamicJobFlowSandbox.java +++ b/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/term/job/DynamicJobFlowSandbox.java @@ -42,7 +42,7 @@ import java.util.stream.Collectors; * Not intended to ever run. Used as a sandbox for "interesting" jobs */ public class DynamicJobFlowSandbox { - protected static final Logger ourLog = LoggerFactory.getLogger(TermCodeSystemDeleteJobTest.class); + protected static final Logger ourLog = LoggerFactory.getLogger(DynamicJobFlowSandbox.class); @Autowired diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/CoordCalculatorTest.java b/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/CoordCalculatorTest.java index 153518a895d..90d9568f988 100644 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/CoordCalculatorTest.java +++ b/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/util/CoordCalculatorTest.java @@ -3,53 +3,37 @@ package ca.uhn.fhir.jpa.util; import org.hibernate.search.engine.spatial.GeoBoundingBox; import org.hibernate.search.engine.spatial.GeoPoint; import org.junit.jupiter.api.Test; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; import static org.junit.jupiter.api.Assertions.assertEquals; public class CoordCalculatorTest { - // CHIN and UHN coordinates from Google Maps - // Distance and bearing from https://www.movable-type.co.uk/scripts/latlong.html - public static final double LATITUDE_CHIN = 43.65513; - public static final double LONGITUDE_CHIN = -79.4170007; - public static final double LATITUDE_UHN = 43.656765; - public static final double LONGITUDE_UHN = -79.3987645; - public static final double DISTANCE_KM_CHIN_TO_UHN = 1.478; - public static final double BEARING_CHIN_TO_UHN = 82 + (55.0 / 60) + (46.0 / 3600); - - // A Fiji island near the anti-meridian - public static final double LATITUDE_TAVEUNI = -16.8488893; - public static final double LONGITIDE_TAVEUNI = 179.889793; - // enough distance from point to cross anti-meridian - public static final double DISTANCE_TAVEUNI = 100.0; @Test public void testCHINToUHN() { - GeoPoint result = CoordCalculator.findTarget(LATITUDE_CHIN, LONGITUDE_CHIN, BEARING_CHIN_TO_UHN, DISTANCE_KM_CHIN_TO_UHN); + GeoPoint result = CoordCalculator.findTarget(CoordCalculatorTestUtil.LATITUDE_CHIN, CoordCalculatorTestUtil.LONGITUDE_CHIN, CoordCalculatorTestUtil.BEARING_CHIN_TO_UHN, CoordCalculatorTestUtil.DISTANCE_KM_CHIN_TO_UHN); - assertEquals(LATITUDE_UHN, result.latitude(), 0.0001); - assertEquals(LONGITUDE_UHN, result.longitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LATITUDE_UHN, result.latitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LONGITUDE_UHN, result.longitude(), 0.0001); } @Test public void testBox() { - GeoBoundingBox box = CoordCalculator.getBox(LATITUDE_CHIN, LONGITUDE_CHIN, 1.0); + GeoBoundingBox box = CoordCalculator.getBox(CoordCalculatorTestUtil.LATITUDE_CHIN, CoordCalculatorTestUtil.LONGITUDE_CHIN, 1.0); double expectedLatitudeDelta = 0.0090; - assertEquals(LATITUDE_CHIN - expectedLatitudeDelta, box.bottomRight().latitude(), 0.0001); - assertEquals(LATITUDE_CHIN + expectedLatitudeDelta, box.topLeft().latitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LATITUDE_CHIN - expectedLatitudeDelta, box.bottomRight().latitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LATITUDE_CHIN + expectedLatitudeDelta, box.topLeft().latitude(), 0.0001); double expectedLongitudeDelta = 0.012414; - assertEquals(LONGITUDE_CHIN - expectedLongitudeDelta, box.topLeft().longitude(), 0.0001); - assertEquals(LONGITUDE_CHIN + expectedLongitudeDelta, box.bottomRight().longitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LONGITUDE_CHIN - expectedLongitudeDelta, box.topLeft().longitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LONGITUDE_CHIN + expectedLongitudeDelta, box.bottomRight().longitude(), 0.0001); } @Test public void testOnPrimeMeridian() { double meridianLongitide = 0.0; - GeoBoundingBox box = CoordCalculator.getBox(LATITUDE_CHIN, meridianLongitide, 1.0); + GeoBoundingBox box = CoordCalculator.getBox(CoordCalculatorTestUtil.LATITUDE_CHIN, meridianLongitide, 1.0); double expectedLatitudeDelta = 0.0090; - assertEquals(LATITUDE_CHIN - expectedLatitudeDelta, box.bottomRight().latitude(), 0.0001); - assertEquals(LATITUDE_CHIN + expectedLatitudeDelta, box.topLeft().latitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LATITUDE_CHIN - expectedLatitudeDelta, box.bottomRight().latitude(), 0.0001); + assertEquals(CoordCalculatorTestUtil.LATITUDE_CHIN + expectedLatitudeDelta, box.topLeft().latitude(), 0.0001); double expectedLongitudeDelta = 0.012414; assertEquals(meridianLongitide - expectedLongitudeDelta, box.topLeft().longitude(), 0.0001); assertEquals(meridianLongitide + expectedLongitudeDelta, box.bottomRight().longitude(), 0.0001); @@ -57,14 +41,14 @@ public class CoordCalculatorTest { @Test public void testOnAntiMeridian() { - GeoBoundingBox box = CoordCalculator.getBox(LATITUDE_TAVEUNI, LONGITIDE_TAVEUNI, 100.0); + GeoBoundingBox box = CoordCalculator.getBox(CoordCalculatorTestUtil.LATITUDE_TAVEUNI, CoordCalculatorTestUtil.LONGITIDE_TAVEUNI, 100.0); double expectedLatitudeDelta = 0.90; - assertEquals(LATITUDE_TAVEUNI - expectedLatitudeDelta, box.bottomRight().latitude(), 0.01); - assertEquals(LATITUDE_TAVEUNI + expectedLatitudeDelta, box.topLeft().latitude(), 0.01); + assertEquals(CoordCalculatorTestUtil.LATITUDE_TAVEUNI - expectedLatitudeDelta, box.bottomRight().latitude(), 0.01); + assertEquals(CoordCalculatorTestUtil.LATITUDE_TAVEUNI + expectedLatitudeDelta, box.topLeft().latitude(), 0.01); double expectedLongitudeDelta = 0.94; - assertEquals(LONGITIDE_TAVEUNI - expectedLongitudeDelta, box.topLeft().longitude(), 0.01); + assertEquals(CoordCalculatorTestUtil.LONGITIDE_TAVEUNI - expectedLongitudeDelta, box.topLeft().longitude(), 0.01); // This case wraps - assertEquals(LONGITIDE_TAVEUNI + expectedLongitudeDelta - 360.0, box.bottomRight().longitude(), 0.01); + assertEquals(CoordCalculatorTestUtil.LONGITIDE_TAVEUNI + expectedLongitudeDelta - 360.0, box.bottomRight().longitude(), 0.01); } } diff --git a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ZContextCloserDstu2Test.java b/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ZContextCloserDstu2Test.java deleted file mode 100644 index 1614fb2ae98..00000000000 --- a/hapi-fhir-jpaserver-test-utilities/src/test/java/ca/uhn/fhir/jpa/z/ZContextCloserDstu2Test.java +++ /dev/null @@ -1,20 +0,0 @@ -package ca.uhn.fhir.jpa.z; - -import org.junit.jupiter.api.Test; -import org.springframework.test.annotation.DirtiesContext; - -import ca.uhn.fhir.jpa.dao.dstu2.BaseJpaDstu2Test; - -public class ZContextCloserDstu2Test extends BaseJpaDstu2Test { - - /** - * this is just here to close the context when this package's test are done - */ - @Test - @DirtiesContext() - public void testCloseContext() { - // nothing - } - - -} diff --git a/pom.xml b/pom.xml index 1edc0349c65..f56bf51f30e 100644 --- a/pom.xml +++ b/pom.xml @@ -2742,6 +2742,10 @@ hapi-fhir-docs hapi-fhir-test-utilities hapi-fhir-jpaserver-test-utilities + hapi-fhir-jpaserver-test-dstu2 + hapi-fhir-jpaserver-test-dstu3 + hapi-fhir-jpaserver-test-r4 + hapi-fhir-jpaserver-test-r5 hapi-fhir-jpaserver-elastic-test-utilities hapi-tinder-plugin hapi-tinder-test diff --git a/test-job-template.yml b/test-job-template.yml index 0d2ca2ea516..dde0f4d0f0d 100644 --- a/test-job-template.yml +++ b/test-job-template.yml @@ -39,6 +39,7 @@ jobs: vmImage: ubuntu-latest steps: - script: echo testing module ${{ p.module }} + - script: echo $(SourceBranchName) - task: DockerInstaller@0 displayName: Docker Installer inputs: