Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unit: 3 unit tests failing #14

Open
Bugs5382 opened this issue Dec 9, 2023 · 1 comment
Open

unit: 3 unit tests failing #14

Bugs5382 opened this issue Dec 9, 2023 · 1 comment
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed

Comments

@Bugs5382
Copy link
Owner

Bugs5382 commented Dec 9, 2023

Unit test: hl7.build.test.ts

    test.skip('...can chain component setters', async () => {
      message.set("PV1.7").set(0).set("PV1.7.2", "Jones").set("PV1.7.3", "John");
      message.set("PV1.7").set(1).set("PV1.7.2", "Smith").set("PV1.7.3", "Bob");
      expect(message.toString()).toContain("PV1|||||||^Jones^John~^Smith^Bob");
    });
   test.skip('...should be able to set repeating fields', async () => {
      message.set('PID.3').set(0).set('PID.3.1', 'abc');
      message.set('PID.3').set(0).set('PID.3.5', 'MRN');
      message.set('PID.3').set(1).set('PID.3.1', 123);
      message.set('PID.3').set(1).set('PID.3.5', 'ID');
      expect(message.toString()).toContain("PID|||abc^^^^MRN~123^^^^ID");
    });
    test.skip('... add segment EVN field - using full path', async () => {
      const segment = message.addSegment('EVN')
      segment.set('EVN.2.1', '20081231')
      expect(message.toString()).toBe("MSH|^~\\&|||||20081231||ADT^A01^ADT_A01|12345||2.7\rEVN||20081231")
    })

I been troubleshooting the issue for a while and can't nail it down. Limits functionally and also not 1:1 of the way it's supposed to work

@Bugs5382 Bugs5382 added bug Something isn't working help wanted Extra attention is needed good first issue Good for newcomers labels Dec 9, 2023
@Bugs5382 Bugs5382 changed the title unit: 2 unit tests failing unit: 3 unit tests failing Dec 9, 2023
@Bugs5382
Copy link
Owner Author

Related Issue: #33

Bugs5382 added a commit that referenced this issue Jun 25, 2024
- this was not needed, all unit tests pass except still the three we are trying to fix
- un-ignore the tests to start troubleshooting #14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed
Projects
Development

When branches are created from issues, their pull requests are automatically linked.

1 participant