Skip to content

Commit

Permalink
adjustments from IDE notes
Browse files Browse the repository at this point in the history
  • Loading branch information
the-andrew committed Jan 10, 2025
1 parent 1be93c5 commit f3a7b35
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 23 deletions.
9 changes: 0 additions & 9 deletions prime-router/src/main/kotlin/azure/SenderFunction.kt
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@ import com.microsoft.azure.functions.annotation.AuthorizationLevel
import com.microsoft.azure.functions.annotation.FunctionName
import com.microsoft.azure.functions.annotation.HttpTrigger
import gov.cdc.prime.router.azure.db.enums.TaskAction
import gov.cdc.prime.router.azure.observability.event.IReportStreamEventService
import gov.cdc.prime.router.azure.observability.event.ReportStreamEventService
import gov.cdc.prime.router.azure.service.SubmissionResponseBuilder
import gov.cdc.prime.router.cli.LookupTableCompareMappingCommand
import gov.cdc.prime.router.metadata.ObservationMappingConstants
import gov.cdc.prime.router.tokens.AuthenticatedClaims
Expand All @@ -22,12 +19,6 @@ import org.apache.logging.log4j.kotlin.Logging
class SenderFunction(
private val workflowEngine: WorkflowEngine = WorkflowEngine(),
private val actionHistory: ActionHistory = ActionHistory(TaskAction.receive),
private val reportEventService: IReportStreamEventService = ReportStreamEventService(
workflowEngine.db,
workflowEngine.azureEventService,
workflowEngine.reportService
),
private val submissionResponseBuilder: SubmissionResponseBuilder = SubmissionResponseBuilder(),
) : RequestFunction(workflowEngine),
Logging {

Expand Down
22 changes: 8 additions & 14 deletions prime-router/src/test/kotlin/azure/SenderFunctionTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ class SenderFunctionTest {
val accessSpy = spyk(DatabaseAccess(connection))
val metadata = UnitTestUtils.simpleMetadata
val settings = mockkClass(SettingsProvider::class)
val serializer = spyk(Hl7Serializer(metadata, settings))
val blobMock = mockkClass(BlobAccess::class)
val queueMock = mockkClass(QueueAccess::class)
val timing1 = mockkClass(Receiver.Timing::class)
private val serializer = spyk(Hl7Serializer(metadata, settings))
private val queueMock = mockkClass(QueueAccess::class)
private val timing1 = mockkClass(Receiver.Timing::class)

val REQ_BODY_TEST_CSV = "test code,test description,coding system\n" +
"97097-0,SARS-CoV-2 (COVID-19) Ag [Presence] in Upper respiratory specimen by Rapid immunoassay,LOINC\n" +
Expand Down Expand Up @@ -114,13 +114,7 @@ class SenderFunctionTest {
ObservationMappingConstants.CONDITION_NAME_KEY
),
listOf(
"80382-5",
"6142004",
"SNOMEDCT",
"Influenza (disorder)"
),
listOf(
"260373001",
"00001",
"Some Condition Code",
"Condition Code System",
"Condition Name"
Expand All @@ -131,15 +125,15 @@ class SenderFunctionTest {

val codeToConditionMapping = listOf(
mapOf(
"test code" to "001",
"test code" to "00001",
"test description" to "test description 1",
"coding system" to "LOINC",
"coding system" to "Condition Code System",
"mapped?" to "Y"
),
mapOf(
"test code" to "002",
"test code" to "00002",
"test description" to "test description 2",
"coding system" to "LOINC",
"coding system" to "Another Condition Code System",
"mapped?" to "N"
)
)
Expand Down

0 comments on commit f3a7b35

Please sign in to comment.