@cyclonedx/cdxgen 10.1.3 → 10.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/utils.test.js CHANGED
@@ -1216,7 +1216,7 @@ test("parse github actions workflow data", () => {
1216
1216
  dep_list = parseGitHubWorkflowData(
1217
1217
  readFileSync("./.github/workflows/repotests.yml", { encoding: "utf-8" })
1218
1218
  );
1219
- expect(dep_list.length).toEqual(8);
1219
+ expect(dep_list.length).toEqual(9);
1220
1220
  expect(dep_list[0]).toEqual({
1221
1221
  group: "actions",
1222
1222
  name: "checkout",
@@ -2712,6 +2712,21 @@ test("parse pyproject.toml", () => {
2712
2712
  });
2713
2713
  });
2714
2714
 
2715
+ test("parse pyproject.toml with custom poetry source", () => {
2716
+ const pkg = parsePyProjectToml(
2717
+ "./test/data/pyproject_with_custom_poetry_source.toml"
2718
+ );
2719
+ expect(pkg).toEqual({
2720
+ name: "cpggen",
2721
+ version: "1.9.0",
2722
+ description:
2723
+ "Generate CPG for multiple languages for code and threat analysis",
2724
+ author: "Team AppThreat <cloud@appthreat.com>",
2725
+ homepage: { url: "https://github.com/AppThreat/cpggen" },
2726
+ repository: { url: "https://github.com/AppThreat/cpggen" }
2727
+ });
2728
+ });
2729
+
2715
2730
  test("parse poetry.lock", async () => {
2716
2731
  let retMap = await parsePoetrylockData(
2717
2732
  readFileSync("./test/data/poetry.lock", { encoding: "utf-8" }),
@@ -3218,7 +3233,7 @@ test("parse swift deps files", () => {
3218
3233
  }
3219
3234
  ]);
3220
3235
  let pkgList = parseSwiftResolved("./test/data/Package.resolved");
3221
- expect(pkgList.length).toEqual(4);
3236
+ expect(pkgList.length).toEqual(6);
3222
3237
  expect(pkgList[0]).toEqual({
3223
3238
  name: "swift-argument-parser",
3224
3239
  group: "github.com/apple",
@@ -3242,7 +3257,7 @@ test("parse swift deps files", () => {
3242
3257
  repository: { url: "https://github.com/apple/swift-argument-parser" }
3243
3258
  });
3244
3259
  pkgList = parseSwiftResolved("./test/data/Package2.resolved");
3245
- expect(pkgList.length).toEqual(4);
3260
+ expect(pkgList.length).toEqual(6);
3246
3261
  expect(pkgList[0]).toEqual({
3247
3262
  name: "swift-argument-parser",
3248
3263
  group: "github.com/apple",