Skip to content

Commit a56f1bf

Browse files
committed
Improve generator by randomizing all remaining fields
1 parent 3c99a5d commit a56f1bf

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

publication/src/test/scala/hmda/publication/reports/disclosure/D5XProtocolSpec.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ class D5XProtocolSpec extends PropSpec with PropertyChecks with MustMatchers {
1919
d5X.toJson mustBe JsObject(
2020
"respondentId" -> JsString(d5X.respondentId),
2121
"institutionName" -> JsString(d5X.institutionName),
22-
"table" -> JsString("D5-X"),
22+
"table" -> JsString(d5X.table),
2323
"type" -> JsString("Disclosure"),
24-
"desc" -> JsString("description"),
24+
"desc" -> JsString(d5X.description),
2525
"year" -> JsNumber(d5X.year),
2626
"reportDate" -> JsString(d5X.reportDate),
2727
"msa" -> d5X.msa.toJson,

publication/src/test/scala/hmda/publication/reports/disclosure/DisclosureReportGenerators.scala

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ object DisclosureReportGenerators {
1414
msa <- msaReportGen
1515
applicantIncomes <- Gen.listOfN(5, applicantIncomeGen)
1616
total <- totalDispositionGen
17-
} yield D5X(respId, instName, year, msa, applicantIncomes, total, "D5-X", "description")
17+
table <- Gen.alphaStr
18+
description <- Gen.alphaStr
19+
} yield D5X(respId, instName, year, msa, applicantIncomes, total, table, description)
1820
}
1921

2022
}

0 commit comments

Comments
 (0)