mirror of
				https://github.com/gradle/gradle-build-action.git
				synced 2025-11-04 09:58:56 +08:00 
			
		
		
		
	Fix dependency-graph with configuration-cache
When state is reused from the configuration cache, no dependencies are resolved. This fix prevents the action from submitting an empty dependency graph in this case.
This commit is contained in:
		@@ -29,7 +29,6 @@ class TestDependencyGraph extends BaseInitScriptTest {
 | 
			
		||||
 | 
			
		||||
        then:
 | 
			
		||||
        assert reportFile.exists()
 | 
			
		||||
        assert gitHubOutputFile.text == "dependency-graph-file=${reportFile.absolutePath}\n"
 | 
			
		||||
 | 
			
		||||
        where:
 | 
			
		||||
        testGradleVersion << [GRADLE_8_X]
 | 
			
		||||
@@ -116,7 +115,6 @@ class TestDependencyGraph extends BaseInitScriptTest {
 | 
			
		||||
            GITHUB_DEPENDENCY_GRAPH_SHA: "123456",
 | 
			
		||||
            GITHUB_DEPENDENCY_GRAPH_WORKSPACE: testProjectDir.absolutePath,
 | 
			
		||||
            DEPENDENCY_GRAPH_REPORT_DIR: reportsDir.absolutePath,
 | 
			
		||||
            GITHUB_OUTPUT: gitHubOutputFile.absolutePath
 | 
			
		||||
        ]
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
@@ -127,8 +125,4 @@ class TestDependencyGraph extends BaseInitScriptTest {
 | 
			
		||||
    def getReportFile() {
 | 
			
		||||
        return new File(reportsDir, "CORRELATOR.json")
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    def getGitHubOutputFile() {
 | 
			
		||||
        return new File(testProjectDir, "GITHUB_OUTPUT")
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user