Skip to content

Commit 5c4bfff

Browse files
committed
Fix unit test failures
Unit tests "manually" read the `JdkInfo*.props` files, and since the file names and property names changed, things broke. Oops.
1 parent 80b391d commit 5c4bfff

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

tests/TestJVM/TestJVM.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ static string GetOutputDirectoryName ()
9393
if (buildName.Contains ('-')) {
9494
buildName = buildName.Substring (0, buildName.IndexOf ('-'));
9595
}
96-
var jdkPropFile = Path.Combine (binDir, buildName, "JdkInfo.props");
96+
var jdkPropFile = Path.Combine (binDir, buildName, "JdkInfo-11.props");
9797
if (!File.Exists (jdkPropFile)) {
9898
return null;
9999
}
@@ -105,7 +105,7 @@ static string GetOutputDirectoryName ()
105105
.Elements (msbuild + "Choose")
106106
.Elements (msbuild + "When")
107107
.Elements (msbuild + "PropertyGroup")
108-
.Elements (msbuild + "JdkJvmPath")
108+
.Elements (msbuild + "JdkJvm11Path")
109109
.FirstOrDefault ();
110110
if (jdkJvmPath == null) {
111111
return null;

tests/Xamarin.Android.Tools.Bytecode-Tests/ConfiguredJdkInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ static string ReadJavaSdkDirectoryFromJdkInfoProps ()
3333
if (buildName.IndexOf ("-", StringComparison.Ordinal) >= 0) {
3434
buildName = buildName.Substring (0, buildName.IndexOf ('-'));
3535
}
36-
var jdkPropFile = Path.Combine (binDir, buildName, "JdkInfo.props");
36+
var jdkPropFile = Path.Combine (binDir, buildName, "JdkInfo-8.props");
3737
if (!File.Exists (jdkPropFile)) {
3838
return null;
3939
}
@@ -43,7 +43,7 @@ static string ReadJavaSdkDirectoryFromJdkInfoProps ()
4343
var jdkProps = XDocument.Load (jdkPropFile);
4444
var jdkPath = jdkProps.Elements ()
4545
.Elements (msbuild + "PropertyGroup")
46-
.Elements (msbuild + "JavaSdkDirectory")
46+
.Elements (msbuild + "Java8SdkDirectory")
4747
.FirstOrDefault ();
4848
if (jdkPath == null) {
4949
return null;

0 commit comments

Comments
 (0)