From c21d58c948cf63b7d7e290ec0f6379049b21ccfc Mon Sep 17 00:00:00 2001 From: Kaspar Lyngsie Date: Wed, 15 Nov 2023 23:49:09 +0100 Subject: [PATCH] fix: updated dep graph fixture --- ...aph-gradleNormalizeDeps-failed-search.json | 6 +-- .../basic-with-deps/dep-graph.json | 6 +-- .../basic-with-failed-dep/dep-graph.json | 6 +-- .../configuration-consistency/dep-graph.json | 6 +-- .../custom-configuration/dep-graph.json | 6 +-- .../empty-build-gradle-in-root/dep-graph.json | 6 +-- .../empty-project/dep-graph.json | 6 +-- .../kts-basic-with-deps/dep-graph.json | 6 +-- .../dep-graph.json | 6 +-- .../kts-strict-lock-mode/dep-graph.json | 6 +-- .../kts-version-catalog-module/dep-graph.json | 6 +-- .../platform-project-mvn-bom/dep-graph.json | 6 +-- .../repo-content-filtering/dep-graph.json | 6 +-- .../version-catalog-settings/dep-graph.json | 6 +-- .../version-catalog-toml/dep-graph.json | 6 +-- .../with-lock-file/dep-graph.json | 8 ++-- .../fixtures/pruned-spring-app/dep-graph.json | 6 +-- test/manual/gradle-stdout.spec.ts | 12 +++--- test/system/kotlin.test.ts | 2 +- test/system/multi-module.test.ts | 38 +++++++++++-------- test/system/plugin.test.ts | 2 +- 21 files changed, 82 insertions(+), 76 deletions(-) diff --git a/test/fixtures-with-wrappers/basic-with-deps/dep-graph-gradleNormalizeDeps-failed-search.json b/test/fixtures-with-wrappers/basic-with-deps/dep-graph-gradleNormalizeDeps-failed-search.json index bd527b0..12c0970 100644 --- a/test/fixtures-with-wrappers/basic-with-deps/dep-graph-gradleNormalizeDeps-failed-search.json +++ b/test/fixtures-with-wrappers/basic-with-deps/dep-graph-gradleNormalizeDeps-failed-search.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "basic-with-deps@unspecified", "info": { - "name": ".", + "name": "basic-with-deps", "version": "unspecified" } }, @@ -66,7 +66,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "basic-with-deps@unspecified", "deps": [ { "nodeId": "unknown:guava-87e0fd1df874ea3cbe577702fe6f17068b790fd8@unknown" diff --git a/test/fixtures-with-wrappers/basic-with-deps/dep-graph.json b/test/fixtures-with-wrappers/basic-with-deps/dep-graph.json index 54fb200..b4a42ba 100644 --- a/test/fixtures-with-wrappers/basic-with-deps/dep-graph.json +++ b/test/fixtures-with-wrappers/basic-with-deps/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "basic-with-deps@unspecified", "info": { - "name": ".", + "name": "basic-with-deps", "version": "unspecified" } }, @@ -66,7 +66,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "basic-with-deps@unspecified", "deps": [ { "nodeId": "com.google.guava:guava@30.1.1-jre" diff --git a/test/fixtures-with-wrappers/basic-with-failed-dep/dep-graph.json b/test/fixtures-with-wrappers/basic-with-failed-dep/dep-graph.json index 54fb200..2109622 100644 --- a/test/fixtures-with-wrappers/basic-with-failed-dep/dep-graph.json +++ b/test/fixtures-with-wrappers/basic-with-failed-dep/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "basic-with-failed-dep@unspecified", "info": { - "name": ".", + "name": "basic-with-failed-dep", "version": "unspecified" } }, @@ -66,7 +66,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "basic-with-failed-dep@unspecified", "deps": [ { "nodeId": "com.google.guava:guava@30.1.1-jre" diff --git a/test/fixtures-with-wrappers/configuration-consistency/dep-graph.json b/test/fixtures-with-wrappers/configuration-consistency/dep-graph.json index f3f2637..705d2ce 100644 --- a/test/fixtures-with-wrappers/configuration-consistency/dep-graph.json +++ b/test/fixtures-with-wrappers/configuration-consistency/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "configuration-consistency@unspecified", "info": { - "name": ".", + "name": "configuration-consistency", "version": "unspecified" } }, @@ -73,7 +73,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "configuration-consistency@unspecified", "deps": [ { "nodeId": "org.codehaus.groovy:groovy@3.0.1" diff --git a/test/fixtures-with-wrappers/custom-configuration/dep-graph.json b/test/fixtures-with-wrappers/custom-configuration/dep-graph.json index 337adcc..48e55cb 100644 --- a/test/fixtures-with-wrappers/custom-configuration/dep-graph.json +++ b/test/fixtures-with-wrappers/custom-configuration/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "custom-configuration@unspecified", "info": { - "name": ".", + "name": "custom-configuration", "version": "unspecified" } }, @@ -38,7 +38,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "custom-configuration@unspecified", "deps": [ { "nodeId": "org.mockito:mockito-core@4.6.1" diff --git a/test/fixtures-with-wrappers/empty-build-gradle-in-root/dep-graph.json b/test/fixtures-with-wrappers/empty-build-gradle-in-root/dep-graph.json index aa4edff..5abe6aa 100644 --- a/test/fixtures-with-wrappers/empty-build-gradle-in-root/dep-graph.json +++ b/test/fixtures-with-wrappers/empty-build-gradle-in-root/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "no-build-gradle-in-root@unspecified", "info": { - "name": ".", + "name": "no-build-gradle-in-root", "version": "unspecified" } } @@ -17,7 +17,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "no-build-gradle-in-root@unspecified", "deps": [] } ] diff --git a/test/fixtures-with-wrappers/empty-project/dep-graph.json b/test/fixtures-with-wrappers/empty-project/dep-graph.json index aa4edff..6f0b312 100644 --- a/test/fixtures-with-wrappers/empty-project/dep-graph.json +++ b/test/fixtures-with-wrappers/empty-project/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "basic@unspecified", "info": { - "name": ".", + "name": "basic", "version": "unspecified" } } @@ -17,7 +17,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "basic@unspecified", "deps": [] } ] diff --git a/test/fixtures-with-wrappers/kts-basic-with-deps/dep-graph.json b/test/fixtures-with-wrappers/kts-basic-with-deps/dep-graph.json index 906bf3a..9866975 100644 --- a/test/fixtures-with-wrappers/kts-basic-with-deps/dep-graph.json +++ b/test/fixtures-with-wrappers/kts-basic-with-deps/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@1.0.0-SNAPSHOT", + "id": "kts-basic-with-deps@1.0.0-SNAPSHOT", "info": { - "name": ".", + "name": "kts-basic-with-deps", "version": "1.0.0-SNAPSHOT" } }, @@ -101,7 +101,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@1.0.0-SNAPSHOT", + "pkgId": "kts-basic-with-deps@1.0.0-SNAPSHOT", "deps": [ { "nodeId": "org.jetbrains.kotlin:kotlin-stdlib-jdk8@1.3.21" diff --git a/test/fixtures-with-wrappers/kts-configuration-consistency/dep-graph.json b/test/fixtures-with-wrappers/kts-configuration-consistency/dep-graph.json index 906bf3a..6a69f55 100644 --- a/test/fixtures-with-wrappers/kts-configuration-consistency/dep-graph.json +++ b/test/fixtures-with-wrappers/kts-configuration-consistency/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@1.0.0-SNAPSHOT", + "id": "kts-configuration-consistency@1.0.0-SNAPSHOT", "info": { - "name": ".", + "name": "kts-configuration-consistency", "version": "1.0.0-SNAPSHOT" } }, @@ -101,7 +101,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@1.0.0-SNAPSHOT", + "pkgId": "kts-configuration-consistency@1.0.0-SNAPSHOT", "deps": [ { "nodeId": "org.jetbrains.kotlin:kotlin-stdlib-jdk8@1.3.21" diff --git a/test/fixtures-with-wrappers/kts-strict-lock-mode/dep-graph.json b/test/fixtures-with-wrappers/kts-strict-lock-mode/dep-graph.json index b3a7910..5c524fd 100644 --- a/test/fixtures-with-wrappers/kts-strict-lock-mode/dep-graph.json +++ b/test/fixtures-with-wrappers/kts-strict-lock-mode/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@1.0.0-SNAPSHOT", + "id": "kts-strict-lock-mode@1.0.0-SNAPSHOT", "info": { - "name": ".", + "name": "kts-strict-lock-mode", "version": "1.0.0-SNAPSHOT" } }, @@ -101,7 +101,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@1.0.0-SNAPSHOT", + "pkgId": "kts-strict-lock-mode@1.0.0-SNAPSHOT", "deps": [ { "nodeId": "org.jetbrains.kotlin:kotlin-stdlib-jdk8@1.3.21" diff --git a/test/fixtures-with-wrappers/kts-version-catalog-module/dep-graph.json b/test/fixtures-with-wrappers/kts-version-catalog-module/dep-graph.json index b4ba9e6..e064677 100644 --- a/test/fixtures-with-wrappers/kts-version-catalog-module/dep-graph.json +++ b/test/fixtures-with-wrappers/kts-version-catalog-module/dep-graph.json @@ -1,13 +1,13 @@ { "graph": { - "nodes": [{ "deps": [], "nodeId": "root-node", "pkgId": ".@1.0" }], + "nodes": [{ "deps": [], "nodeId": "root-node", "pkgId": "kts-version-catalog-module@1.0" }], "rootNodeId": "root-node" }, "pkgManager": { "name": "gradle" }, "pkgs": [ { - "id": ".@1.0", - "info": { "name": ".", "version": "1.0" } + "id": "kts-version-catalog-module@1.0", + "info": { "name": "kts-version-catalog-module", "version": "1.0" } } ], "schemaVersion": "1.2.0" diff --git a/test/fixtures-with-wrappers/platform-project-mvn-bom/dep-graph.json b/test/fixtures-with-wrappers/platform-project-mvn-bom/dep-graph.json index 8b0ab30..be08569 100644 --- a/test/fixtures-with-wrappers/platform-project-mvn-bom/dep-graph.json +++ b/test/fixtures-with-wrappers/platform-project-mvn-bom/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "platform-project-mvn-bom@unspecified", "info": { - "name": ".", + "name": "platform-project-mvn-bom", "version": "unspecified" } }, @@ -45,7 +45,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "platform-project-mvn-bom@unspecified", "deps": [ { "nodeId": "org.springframework.boot:spring-boot-dependencies@1.5.8.RELEASE" diff --git a/test/fixtures-with-wrappers/repo-content-filtering/dep-graph.json b/test/fixtures-with-wrappers/repo-content-filtering/dep-graph.json index 1b8f136..78fbba8 100644 --- a/test/fixtures-with-wrappers/repo-content-filtering/dep-graph.json +++ b/test/fixtures-with-wrappers/repo-content-filtering/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "repo-content-filtering@unspecified", "info": { - "name": ".", + "name": "repo-content-filtering", "version": "unspecified" } }, @@ -80,7 +80,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "repo-content-filtering@unspecified", "deps": [ { "nodeId": "com.google.guava:guava@30.1.1-jre" diff --git a/test/fixtures-with-wrappers/version-catalog-settings/dep-graph.json b/test/fixtures-with-wrappers/version-catalog-settings/dep-graph.json index ffe742c..ff9c1b0 100644 --- a/test/fixtures-with-wrappers/version-catalog-settings/dep-graph.json +++ b/test/fixtures-with-wrappers/version-catalog-settings/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "version-catalogues@unspecified", "info": { - "name": ".", + "name": "version-catalogues", "version": "unspecified" } }, @@ -38,7 +38,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "version-catalogues@unspecified", "deps": [ { "nodeId": "org.codehaus.groovy:groovy@3.0.5" diff --git a/test/fixtures-with-wrappers/version-catalog-toml/dep-graph.json b/test/fixtures-with-wrappers/version-catalog-toml/dep-graph.json index bdb5363..f222758 100644 --- a/test/fixtures-with-wrappers/version-catalog-toml/dep-graph.json +++ b/test/fixtures-with-wrappers/version-catalog-toml/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "version-catalog-toml@unspecified", "info": { - "name": ".", + "name": "version-catalog-toml", "version": "unspecified" } }, @@ -94,7 +94,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "version-catalog-toml@unspecified", "deps": [ { "nodeId": "org.mockito:mockito-core@4.5.1" diff --git a/test/fixtures-with-wrappers/with-lock-file/dep-graph.json b/test/fixtures-with-wrappers/with-lock-file/dep-graph.json index b6fa964..0136bbe 100644 --- a/test/fixtures-with-wrappers/with-lock-file/dep-graph.json +++ b/test/fixtures-with-wrappers/with-lock-file/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "with-lock-file@unspecified", "info": { - "name": ".", + "name": "with-lock-file", "version": "unspecified" } }, @@ -73,7 +73,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "with-lock-file@unspecified", "deps": [ { "nodeId": "org.codehaus.groovy:groovy@3.0.3" @@ -144,4 +144,4 @@ } ] } -} \ No newline at end of file +} diff --git a/test/fixtures/pruned-spring-app/dep-graph.json b/test/fixtures/pruned-spring-app/dep-graph.json index aac7afc..374a76e 100644 --- a/test/fixtures/pruned-spring-app/dep-graph.json +++ b/test/fixtures/pruned-spring-app/dep-graph.json @@ -5,9 +5,9 @@ }, "pkgs": [ { - "id": ".@unspecified", + "id": "pruned-spring-app@unspecified", "info": { - "name": ".", + "name": "pruned-spring-app", "version": "unspecified" } }, @@ -45,7 +45,7 @@ "nodes": [ { "nodeId": "root-node", - "pkgId": ".@unspecified", + "pkgId": "pruned-spring-app@unspecified", "deps": [ { "nodeId": "org.springframework:spring-web@5.3.10" diff --git a/test/manual/gradle-stdout.spec.ts b/test/manual/gradle-stdout.spec.ts index e92aca7..c3cc04b 100644 --- a/test/manual/gradle-stdout.spec.ts +++ b/test/manual/gradle-stdout.spec.ts @@ -5,14 +5,14 @@ describe('findProjectsInExtractedJSON', () => { const fakeRootDir = path.join('dev', 'tardis-master'); it.each` - rootDir | targetFile - ${''} | ${'build.gradle'} - ${null} | ${'build.gradle'} - ${undefined} | ${'build.gradle'} - ${fakeRootDir} | ${path.join(fakeRootDir, 'build.gradle')} + targetFile + ${'build.gradle'} + ${'build.gradle'} + ${'build.gradle'} + ${path.join(fakeRootDir, 'build.gradle')} `( 'project with targetFile `$targetFile` have valid name when rootDir is `$rootDir`', - async ({ rootDir, targetFile }) => { + async ({ targetFile }) => { const jsonExtractedFromGradleStdout = { defaultProject: 'tardis-master', defaultProjectKey: 'tardis-master', diff --git a/test/system/kotlin.test.ts b/test/system/kotlin.test.ts index 4ab2121..307db0e 100644 --- a/test/system/kotlin.test.ts +++ b/test/system/kotlin.test.ts @@ -15,7 +15,7 @@ if (isKotlinSupported) { '.', path.join(fixtureDir('gradle-kts'), 'build.gradle.kts'), ); - expect(result.dependencyGraph.rootPkg.name).toMatch('.'); + expect(result.dependencyGraph.rootPkg.name).toMatch('gradle-kts'); expect(result.meta!.gradleProjectName).toMatch('gradle-kts'); const pkgs = result.dependencyGraph.getDepPkgs(); const nodeIds: string[] = []; diff --git a/test/system/multi-module.test.ts b/test/system/multi-module.test.ts index 3bb8182..5cd19b6 100644 --- a/test/system/multi-module.test.ts +++ b/test/system/multi-module.test.ts @@ -27,7 +27,7 @@ test('multi-project, explicitly targeting a subproject build file', async () => test('multi-project, ran from root, targeting subproj', async () => { const result = await inspect(multiProject, 'subproj/build.gradle'); - expect(result.dependencyGraph.rootPkg.name).toBe('subproj'); + expect(result.dependencyGraph.rootPkg.name).toBe('subproj'); expect(result.meta!.gradleProjectName).toBe('subproj'); expect(result.plugin.meta!.allSubProjectNames).toEqual([]); @@ -71,7 +71,7 @@ test('multi-project: only sub-project has deps and they are returned', async () path.join(multiProject, 'build.gradle'), options, ); - expect(result.dependencyGraph.rootPkg.name).toBe('./subproj'); + expect(result.dependencyGraph.rootPkg.name).toBe('root-proj/subproj'); expect(result.meta!.gradleProjectName).toBe('root-proj/subproj'); expect(result.plugin.meta!.allSubProjectNames).toEqual(['subproj']); @@ -175,7 +175,7 @@ test('multi-project: deps for both projects are returned with allSubProjects fla // It's an array, so we have to scan expect(result.scannedProjects.length).toBe(2); for (const p of result.scannedProjects) { - if (p.depGraph.rootPkg.name === '.') { + if (p.depGraph.rootPkg.name === 'root-proj') { expect(p.meta!.gradleProjectName).toBe('root-proj'); // double parsing to have access to internal depGraph data, no methods available to properly // return the deps nodeIds list that belongs to a node @@ -185,7 +185,7 @@ test('multi-project: deps for both projects are returned with allSubProjects fla // TODO(kyegupov): when the project name issue is solved, change the assertion to: // expect(p.targetFile, 'multi-project' + dirSep + 'build.gradle', 'correct targetFile for the main depRoot'); } else { - expect(p.depGraph.rootPkg.name).toBe('./subproj'); + expect(p.depGraph.rootPkg.name).toBe('root-proj/subproj'); expect(p.meta!.gradleProjectName).toBe('root-proj/subproj'); const pkgs = p.depGraph.getDepPkgs(); @@ -212,7 +212,9 @@ test('single-project: array of one is returned with allSubProjects flag', async { allSubProjects: true }, ); expect(result.scannedProjects.length).toBe(1); - expect(result.scannedProjects[0].depGraph.rootPkg.name).toBe('.'); + expect(result.scannedProjects[0].depGraph.rootPkg.name).toBe( + 'api-configuration', + ); expect(result.scannedProjects[0].meta!.gradleProjectName).toBe( 'api-configuration', ); @@ -282,12 +284,12 @@ test('multi-project: parallel with allSubProjects produces multiple results with } expect(names).toEqual( new Set([ - 'multi-project-parallel', - 'multi-project-parallel/subproj0', - 'multi-project-parallel/subproj1', - 'multi-project-parallel/subproj2', - 'multi-project-parallel/subproj3', - 'multi-project-parallel/subproj4', + 'root-proj', + 'root-proj/subproj0', + 'root-proj/subproj1', + 'root-proj/subproj2', + 'root-proj/subproj3', + 'root-proj/subproj4', ]), ); expect(newNames).toEqual( @@ -310,7 +312,7 @@ test('multi-project: allSubProjects + configuration', async () => { // It's an array, so we have to scan expect(result.scannedProjects.length).toBe(2); for (const p of result.scannedProjects) { - if (p.depGraph.rootPkg.name === '.') { + if (p.depGraph.rootPkg.name === 'root-proj') { expect(p.meta!.gradleProjectName).toBe('root-proj'); // double parsing to have access to internal depGraph data, no methods available to properly @@ -323,7 +325,7 @@ test('multi-project: allSubProjects + configuration', async () => { // expect(p.targetFile, 'multi-project' + dirSep + 'build.gradle', 'correct targetFile for the main depRoot'); } else { // sub project name is included in the root pkg name - expect(p.depGraph.rootPkg.name).toBe('./subproj'); + expect(p.depGraph.rootPkg.name).toBe('root-proj/subproj'); // new sub project name is included in the root pkg name expect(p.meta!.gradleProjectName).toBe('root-proj/subproj'); @@ -376,7 +378,7 @@ test('multi-project-dependency-cycle: scanning all subprojects works fine', asyn expect(result.scannedProjects.length).toBe(2); for (const p of result.scannedProjects) { - if (p.depGraph.rootPkg.name === '.') { + if (p.depGraph.rootPkg.name === 'root-proj') { expect(p.meta!.gradleProjectName).toBe('root-proj'); // double parsing to have access to internal depGraph data, no methods available to properly // return the deps nodeIds list that belongs to a node @@ -570,7 +572,9 @@ test('multi-project: correct deps for subproject with the same name, one depende { subProject: 'subproj' }, ); - expect(result.dependencyGraph.rootPkg.name).toBe('subprojects-same-name/subproj'); + expect(result.dependencyGraph.rootPkg.name).toBe( + 'subprojects-same-name/subproj', + ); expect(result.meta!.gradleProjectName).toBe('subprojects-same-name/subproj'); expect(result.plugin.meta!.allSubProjectNames).toEqual([ 'greeter', @@ -601,7 +605,9 @@ test('multi-project: correct deps for a nested subproject using --sub-project', { subProject: 'lib' }, ); - expect(result.dependencyGraph.rootPkg.name).toBe('gradle-sandbox/greeter/lib'); + expect(result.dependencyGraph.rootPkg.name).toBe( + 'gradle-sandbox/greeter/lib', + ); expect(result.meta!.gradleProjectName).toBe('gradle-sandbox/greeter/lib'); expect(result.plugin.meta!.allSubProjectNames).toEqual([ 'greeter', diff --git a/test/system/plugin.test.ts b/test/system/plugin.test.ts index 0680e95..c59dada 100644 --- a/test/system/plugin.test.ts +++ b/test/system/plugin.test.ts @@ -193,10 +193,10 @@ test('custom dependency resolution via configurations* is supported', async () = test('repeated transitive lines terminated at duplicate node and labeled pruned', async () => { const pathToFixture = fixtureDir('pruned-spring-app'); - const result = await inspect('.', path.join(pathToFixture, 'build.gradle')); const expectedJson = JSON.parse( fs.readFileSync(path.join(pathToFixture, 'dep-graph.json'), 'utf-8'), ); const expected = depGraphLib.createFromJSON(expectedJson); + const result = await inspect('.', path.join(pathToFixture, 'build.gradle')); expect(result.dependencyGraph?.equals(expected)).toBe(true); });