Skip to content

Commit 55e0206

Browse files
committed
1 parent e2967da commit 55e0206

File tree

4 files changed

+11
-6
lines changed

4 files changed

+11
-6
lines changed

build-tools/scripts/Packaging.mk

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,10 +66,8 @@ package-deb: $(ZIP_OUTPUT)
6666
_TEST_ERRORS_BASENAME = xa-test-errors-v$(PRODUCT_VERSION).$(-num-commits-since-version-change)_$(OS_NAME)-$(OS_ARCH)_$(GIT_BRANCH)_$(GIT_COMMIT)
6767

6868
"$(_TEST_ERRORS_BASENAME).zip" package-test-errors:
69-
ifneq ($(wildcard bin/Test*/temp),)
70-
build-tools/scripts/ln-to.sh -r . -o "$(_TEST_ERRORS_BASENAME)" bin/Test*/temp
69+
build-tools/scripts/ln-to.sh -r . -o "$(_TEST_ERRORS_BASENAME)" bin/Test*/temp TestResult-*.xml bin/Test*/TestOutput-*.txt
7170
zip -r "$(_TEST_ERRORS_BASENAME).zip" "$(_TEST_ERRORS_BASENAME)"
72-
endif # We have test error output
7371

7472
_BUILD_STATUS_BUNDLE_INCLUDE = \
7573
Configuration.OperatingSystem.props \

external/xamarin-android-tools

src/Xamarin.Android.Build.Tasks/Tasks/ResolveSdksTask.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,12 @@ public class ResolveSdks : Task
5555
[Output]
5656
public string MonoAndroidBinPath { get; set; }
5757

58+
static readonly string GetMacOSMicrosoftJdkPathsOverrideName = $"GetMacOSMicrosoftJdkPaths jdks override! {typeof (Xamarin.Android.Tools.JdkInfo).AssemblyQualifiedName}";
59+
5860
public override bool Execute ()
5961
{
62+
Log.LogMessage (MessageImportance.High, "{0}", $"# jonp: ResolveSdks: JDKs overridden? {AppDomain.CurrentDomain.GetData (GetMacOSMicrosoftJdkPathsOverrideName)}");
63+
6064
// OS X: $prefix/lib/xamarin.android/xbuild/Xamarin/Android
6165
// Windows: %ProgramFiles(x86)%\MSBuild\Xamarin\Android
6266
if (string.IsNullOrEmpty (MonoAndroidToolsPath)) {

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/PackagingTest.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,9 +208,12 @@ public void ExplicitPackageNamingPolicy ()
208208
}
209209
}
210210

211+
static readonly string GetMacOSMicrosoftJdkPathsOverrideName = $"GetMacOSMicrosoftJdkPaths jdks override! Xamarin.Android.Tools.JdkInfo, Xamarin.Android.Tools.AndroidSdk, Version=1.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065";
212+
211213
[Test]
212214
public void CheckSignApk ([Values(true, false)] bool useApkSigner, [Values(true, false)] bool perAbiApk)
213215
{
216+
Console.WriteLine ($"# jonp: CheckSignApk({useApkSigner}, {perAbiApk}): JDKs overridden? {AppDomain.CurrentDomain.GetData (GetMacOSMicrosoftJdkPathsOverrideName)}");
214217
string ext = Environment.OSVersion.Platform != PlatformID.Unix ? ".bat" : "";
215218
var foundApkSigner = Directory.EnumerateDirectories (Path.Combine (AndroidSdkPath, "build-tools")).Any (dir => Directory.EnumerateFiles (dir, "apksigner"+ ext).Any ());
216219
if (useApkSigner && !foundApkSigner) {
@@ -229,10 +232,10 @@ public void CheckSignApk ([Values(true, false)] bool useApkSigner, [Values(true,
229232
using (var b = CreateApkBuilder (Path.Combine ("temp", TestContext.CurrentContext.Test.Name))) {
230233
b.Verbosity = Microsoft.Build.Framework.LoggerVerbosity.Diagnostic;
231234
Assert.IsTrue (b.Build (proj), "build failed");
232-
Assert.IsTrue (StringAssertEx.ContainsText (b.LastBuildOutput, " 0 Warning(s)"));
235+
Assert.IsTrue (StringAssertEx.ContainsText (b.LastBuildOutput, " 0 Warning(s)"), "First build should not contain warnings!");
233236
proj.AndroidResources.First ().Timestamp = null;
234237
Assert.IsTrue (b.Build (proj), "Second build failed");
235-
Assert.IsTrue (StringAssertEx.ContainsText (b.LastBuildOutput, " 0 Warning(s)"));
238+
Assert.IsTrue (StringAssertEx.ContainsText (b.LastBuildOutput, " 0 Warning(s)"), "Second build should not contain warnings!");
236239
}
237240
}
238241

0 commit comments

Comments
 (0)