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

Add testing for Delta.newDeltaFromGitHistory() #4

Open
hkong-mitre opened this issue Jun 7, 2023 · 0 comments
Open

Add testing for Delta.newDeltaFromGitHistory() #4

hkong-mitre opened this issue Jun 7, 2023 · 0 comments
Labels
addtional tests Additional tests should be written for regression and edge cases

Comments

@hkong-mitre
Copy link
Collaborator

Delta.newDeltaFromGitHistory() is one of the most important functions in Delta.ts, but is difficult to test. Need to figure out a way to consistently test it. The following is code that was originally in Delta.test.ts. A better test should be implemented.

  // it(`newDeltaFromGitHistory() properly builds a Delta object from git history`, async () => {
  //   const delta = await Delta.newDeltaFromGitHistory("2023-02-16T00:00:00.000Z", "2023-03-21T23:59:59.999Z", process.env.CVES_TEST_BASE_DIRECTORY);
  //   console.log(`delta:  ${JSON.stringify(delta, null, 2)}`);
  //   expect(delta.numberOfChanges).toBe(3);
  //   expect(delta.unknown.length).toBe(3);
  //   expect(delta.unknown[0].cveId).toBe(`CVE-1970-0001`);
  // });
@hkong-mitre hkong-mitre added the addtional tests Additional tests should be written for regression and edge cases label Jun 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
addtional tests Additional tests should be written for regression and edge cases
Projects
None yet
Development

No branches or pull requests

2 participants
@hkong-mitre and others