[Gradle] Minor: compare against expected testData in tmpDir

This might become an issue if (when) the editable diff window will
be supported, but for now it doesn't make much difference against
which file we compare the actual output.
This commit is contained in:
Dmitry Savvinov
2023-05-03 09:54:37 +01:00
parent 896292cba1
commit eeb95f2feb
2 changed files with 2 additions and 2 deletions
@@ -18,7 +18,7 @@ class MppDiagnosticsIt : KGPBaseTest() {
@GradleTest
fun testDiagnosticsRenderingSmoke(gradleVersion: GradleVersion) {
project("diagnosticsRenderingSmoke", gradleVersion) {
val expectedOutputFile = projectName.testProjectPath.resolve("expectedOutput.txt").toFile()
val expectedOutputFile = projectPath.resolve("expectedOutput.txt").toFile()
build {
assertEqualsToFile(expectedOutputFile, extractProjectsAndTheirVerboseDiagnostics())
}
@@ -471,7 +471,7 @@ private fun setupProjectFromTestResources(
}
}
internal val String.testProjectPath: Path get() = Paths.get("src", "test", "resources", "testProject", this)
private val String.testProjectPath: Path get() = Paths.get("src", "test", "resources", "testProject", this)
internal fun Path.addDefaultBuildFiles() {
addPluginManagementToSettings()