Skip to content

pt1-4945_FC_run_fields_not_filled#34

Merged
AmirPracti merged 2 commits intomasterfrom
pt1-4945_FC_run_fields_not_filled
Feb 2, 2026
Merged

pt1-4945_FC_run_fields_not_filled#34
AmirPracti merged 2 commits intomasterfrom
pt1-4945_FC_run_fields_not_filled

Conversation

@AmirPracti
Copy link
Copy Markdown
Contributor

https://practitest-uri.atlassian.net/browse/PT1-4945

Firecracker (practitest-firecracker)

What has been changed?

Fixed custom field mapping from XML attributes for both tests and runs. XML
attribute values like skipped="111" were not being populated correctly.

Why is this needed?

Users configure custom field mappings in their JSON config (e.g.,
"---f-306": "?skipped"), but:

  1. Tests: The :skipped XML attribute was being overwritten by a
    computed count (always 0 if no skipped test cases)
  2. Runs: The eval-additional-fields function received wrong data (run
    with only :run-duration) instead of the XML test data containing the
    actual attributes

Implementation Details

  • parser/core.clj: Changed test-data from assoc to merge with
    priority order:

    1. Computed defaults (:skipped, :errors, etc.) - lowest priority
    2. Original XML attributes - user settings override defaults
    3. Required computed fields (:bdd-test?, :pt-test-name, etc.) - must be
      set
  • practitest.clj: Changed make-runs to pass (first xml-test) to
    eval-additional-fields instead of run, so XML attributes are accessible
    for field mapping

    Before (broken): Passed run which came from sf-test-suite->run-def
    output:

    {:run-duration 3.218}
    When evaluating "?skipped", it looked for :skipped in this map and returned
   empty string (key not found).
After (fixed): Passed (first xml-test) which contains the parsed XML 
  testcase data:
  {:name "Login Page error on wrong email format"
   :skipped "111"
   :classname "[chromium] › ..."
   :time "3.098"
   :projectname "chromium"
   :specfilename "01-old-cypress/admin/login.spec.js"
   ...}
    Now "?skipped" correctly resolves to "111" from the XML attribute.

@AmirPracti AmirPracti self-assigned this Feb 1, 2026
@gitstream-cm
Copy link
Copy Markdown

gitstream-cm Bot commented Feb 1, 2026

🥷 Code experts: shmuelko, deshilovPT

shmuelko, deshilovPT have most 🧠 knowledge in the files.

See details

src/practitest_firecracker/parser/core.clj

Knowledge based on git-blame:
deshilovPT: 55%

src/practitest_firecracker/practitest.clj

Knowledge based on git-blame:
shmuelko: 81%
deshilovPT: 17%

✨ Comment /gs review for LinearB AI review. Learn how to automate it here.

@AmirPracti AmirPracti merged commit 18d697a into master Feb 2, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants