feat(decode): a Blastware file's job number, and whether Blastware shows it
The setup block has Series IV's 0x1A layout here too: report flags at k - 9 (bit 0x02 = job number shown) and the number, uint16 BE, at k - 8, kept while switched off. The flag matches Blastware's JobNumber on 2,997 / 2,997 DL2 events that print one and 66,986 / 66,986 that don't. Every printed value is 1 and matches; hidden ones hold real numbers (802, 1012, 1013, 622), so the value is only proven for 1. - ProjectInfo.job_number_enabled / job_number, named as in micromate.setup_block. - write_event_hdf5 stores both as .h5 attrs when read (additive). - The checker reports the number only when shown, and scores a number only SFM shows as a mismatch. The old test that pinned JobNumber as sfm_blank now checks only the ZC cases it also covered. Not carried into the DB, the API or the PDF report yet (needs a column). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
This commit is contained in:
1 parent
15a27d5921
commit
7a58bad28d
10 files changed
+312
-6
No files matched your search
@@ -86,9 +86,8 @@ def test_an_extra_reference_row_is_a_mismatch_with_detail():
|
||||
assert "row_length_disagreements=1" in res["samples.Tran"].detail
|
||||
|
||||
|
||||
def test_job_number_na_and_above_range():
|
||||
res = _results("T1905KDW.5F0W")
|
||||
assert res["JobNumber"].verdict == "sfm_blank"
|
||||
def test_zc_frequency_na_and_above_range():
|
||||
res = _results("T1905KDW.5F0W") # its JobNumber: test_the_job_number_matches_blastware
|
||||
assert res["TranZCFreq"].verdict == "no_reference" # N/A
|
||||
assert res["VertZCFreq"].verdict == "sfm_blank" # >100, SFM has no flag yet
|
||||
|
||||
@@ -172,3 +171,19 @@ def test_a_sensitive_range_event_now_matches():
|
||||
for f in ("GeoRange", "TranPPV", "VertPPV", "LongPPV", "PeakVectorSum",
|
||||
"samples.Tran", "samples.Vert", "samples.Long"):
|
||||
assert res[f].verdict == "match", (f, res[f])
|
||||
|
||||
|
||||
def test_the_job_number_matches_blastware():
|
||||
assert _results("T1905KDW.5F0W", CARVEOUTS)["JobNumber"].verdict == "match"
|
||||
|
||||
|
||||
def test_a_hidden_job_number_is_not_reported():
|
||||
# Flag off: Blastware prints no JobNumber, and SFM's side reports none either.
|
||||
assert sfm_side((FIX / "R352HFZ7.530H").read_bytes()).job_number is None
|
||||
|
||||
|
||||
def test_a_job_number_only_sfm_shows_is_a_mismatch():
|
||||
side = sfm_side((FIX / "R352HFZ7.530H").read_bytes())
|
||||
side.job_number = "1"
|
||||
res = {r.field: r for r in compare(side, parse_xml_report_file(FIX / "R352HFZ7_530H_XML.XML"))}
|
||||
assert res["JobNumber"].verdict == "mismatch"
|
||||
Reference in new issue
Block a user