From ff683413e224ff349170822bd4bd8b910c7554bc Mon Sep 17 00:00:00 2001 From: Shane Neuville Date: Mon, 31 Oct 2022 16:19:22 -0500 Subject: [PATCH 01/20] Fix Author Name (#11015) --- src/TestUtils/src/DeviceTests.Runners/Assets/credits.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/TestUtils/src/DeviceTests.Runners/Assets/credits.html b/src/TestUtils/src/DeviceTests.Runners/Assets/credits.html index 4e88141b25b0..65a209fcf79d 100644 --- a/src/TestUtils/src/DeviceTests.Runners/Assets/credits.html +++ b/src/TestUtils/src/DeviceTests.Runners/Assets/credits.html @@ -7,7 +7,7 @@ All rights reserved.

- Author: Oren Novotny
+ Author: Claire Novotny

About xUnit
From 34c5e9f20a0a3b334cb7b1ce3266fe0b4a994457 Mon Sep 17 00:00:00 2001 From: Shane Neuville Date: Tue, 1 Nov 2022 17:56:18 -0500 Subject: [PATCH 02/20] Add await for color check to avoid crash (#11022) --- .../Elements/Label/LabelTests.Android.cs | 4 ++-- .../Services/Dispatching/DispatcherTests.cs | 17 ++++++++++++++--- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.Android.cs b/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.Android.cs index 47203515d0ff..a452edf41e6a 100644 --- a/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.Android.cs +++ b/src/Controls/tests/DeviceTests/Elements/Label/LabelTests.Android.cs @@ -49,11 +49,11 @@ int GetPlatformMaxLines(LabelHandler labelHandler) => Task ValidateHasColor(Label label, Color color, Action action = null) { - return InvokeOnMainThreadAsync(() => + return InvokeOnMainThreadAsync(async () => { var labelHandler = CreateHandler(label); action?.Invoke(); - labelHandler.PlatformView.AssertContainsColor(color); + await labelHandler.PlatformView.AssertContainsColor(color); }); } } diff --git a/src/Core/tests/DeviceTests/Services/Dispatching/DispatcherTests.cs b/src/Core/tests/DeviceTests/Services/Dispatching/DispatcherTests.cs index 322d7e01bf57..ed9e2ab659f7 100644 --- a/src/Core/tests/DeviceTests/Services/Dispatching/DispatcherTests.cs +++ b/src/Core/tests/DeviceTests/Services/Dispatching/DispatcherTests.cs @@ -183,21 +183,32 @@ public Task CreateTimerRepeatingRepeats() => timer.Interval = TimeSpan.FromMilliseconds(200); timer.IsRepeating = true; + TaskCompletionSource taskCompletionSource = new TaskCompletionSource(); + timer.Tick += (_, _) => { Assert.True(timer.IsRunning, "Timer was not running DURING the tick."); ticks++; + + if (ticks > 1) + taskCompletionSource.SetResult(); }; timer.Start(); Assert.True(timer.IsRunning, "Timer was not running AFTER the tick."); - // Give it time to repeat at least once - await Task.Delay(TimeSpan.FromSeconds(1)); + try + { + await taskCompletionSource.Task.WaitAsync(TimeSpan.FromSeconds(5)).ConfigureAwait(false); + } + catch (TaskCanceledException) + { + // If the task is cancelled we want it to just fall through to the assert + } // If it's repeating, ticks will be greater than 1 - Assert.True(ticks > 1); + Assert.True(ticks > 1, $"# of Ticks: {ticks}, expected > 1"); }); class TimerDisposer : IDisposable From 54220bdf8eda588c63b19ec730a0db6df0b060cd Mon Sep 17 00:00:00 2001 From: Jonathan Dick Date: Wed, 2 Nov 2022 06:37:58 -0400 Subject: [PATCH 03/20] Remove unused reference (#11048) --- .../tests/Xaml.UnitTests/Controls.Xaml.UnitTests.csproj | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Controls/tests/Xaml.UnitTests/Controls.Xaml.UnitTests.csproj b/src/Controls/tests/Xaml.UnitTests/Controls.Xaml.UnitTests.csproj index db82aec28992..b29560fc0473 100644 --- a/src/Controls/tests/Xaml.UnitTests/Controls.Xaml.UnitTests.csproj +++ b/src/Controls/tests/Xaml.UnitTests/Controls.Xaml.UnitTests.csproj @@ -19,7 +19,6 @@ - @@ -52,4 +51,4 @@ - \ No newline at end of file + From 900d5f757567ac0a398772474e91cb406d7cb29c Mon Sep 17 00:00:00 2001 From: Connor Adsit Date: Wed, 2 Nov 2022 07:17:11 -0400 Subject: [PATCH 04/20] Invoke provisionator with AUTH_TOKEN_GITHUB_COM set (#11041) --- eng/pipelines/common/controlgallery-android.yml | 4 +++- eng/pipelines/common/controlgallery-ios.yml | 4 ++++ eng/pipelines/common/controlgallery-windows.yml | 2 ++ eng/pipelines/common/provision.yml | 1 + 4 files changed, 10 insertions(+), 1 deletion(-) diff --git a/eng/pipelines/common/controlgallery-android.yml b/eng/pipelines/common/controlgallery-android.yml index 71227846b08c..5b6904bafb94 100644 --- a/eng/pipelines/common/controlgallery-android.yml +++ b/eng/pipelines/common/controlgallery-android.yml @@ -8,6 +8,8 @@ steps: inputs: provisioning_script: $(provisionator.path) provisioning_extra_args: $(provisionator.extraArguments) + env: + AUTH_TOKEN_GITHUB_COM: $(github--pat--vs-mobiletools-engineering-service2) - task: Bash@3 displayName: 'Cake Provision' @@ -70,4 +72,4 @@ steps: condition: always() inputs: PathtoPublish: '$(build.artifactstagingdirectory)' - ArtifactName: OSXArtifacts \ No newline at end of file + ArtifactName: OSXArtifacts diff --git a/eng/pipelines/common/controlgallery-ios.yml b/eng/pipelines/common/controlgallery-ios.yml index f196d3680247..f8655469516e 100644 --- a/eng/pipelines/common/controlgallery-ios.yml +++ b/eng/pipelines/common/controlgallery-ios.yml @@ -7,6 +7,8 @@ steps: condition: ne(variables['REQUIRED_XCODE'], '') inputs: provisioning_script: $(provisionator.xcode) + env: + AUTH_TOKEN_GITHUB_COM: $(github--pat--vs-mobiletools-engineering-service2) - task: xamops.azdevex.provisionator-task.provisionator@1 displayName: 'Provisionator' @@ -14,6 +16,8 @@ steps: inputs: provisioning_script: $(provisionator.path) provisioning_extra_args: $(provisionator.extraArguments) + env: + AUTH_TOKEN_GITHUB_COM: $(github--pat--vs-mobiletools-engineering-service2) - script: | echo "##vso[task.prependpath]/Library/Frameworks/Mono.framework/Versions/Current/Commands/" diff --git a/eng/pipelines/common/controlgallery-windows.yml b/eng/pipelines/common/controlgallery-windows.yml index c7cc08578b3e..e7f004f54717 100644 --- a/eng/pipelines/common/controlgallery-windows.yml +++ b/eng/pipelines/common/controlgallery-windows.yml @@ -8,6 +8,8 @@ steps: inputs: provisioning_script: $(provisionator.path) provisioning_extra_args: $(provisionator.extraArguments) + env: + AUTH_TOKEN_GITHUB_COM: $(github--pat--vs-mobiletools-engineering-service2) - powershell: | $(System.DefaultWorkingDirectory)/build.ps1 --target provision --TeamProject="$(System.TeamProject)" diff --git a/eng/pipelines/common/provision.yml b/eng/pipelines/common/provision.yml index a1946c0fe0c4..db81b22974b9 100644 --- a/eng/pipelines/common/provision.yml +++ b/eng/pipelines/common/provision.yml @@ -100,6 +100,7 @@ steps: provisioning_script: $(provisionator.vs) env: PROVISIONATOR_CHANNEL: ${{ parameters.provisionatorChannel }} + AUTH_TOKEN_GITHUB_COM: $(github--pat--vs-mobiletools-engineering-service2) - pwsh: | $msbuild = "$env:ProgramFiles/Microsoft Visual Studio/2022/Preview/MSBuild/Current/Bin/MSBuild.exe" From dec92f2e9eee90bce3e7fa18cc225f8b52dd8972 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 2 Nov 2022 13:30:33 +0000 Subject: [PATCH 05/20] Bump Microsoft.Web.WebView2 from 1.0.1370.28 to 1.0.1418.22 (#11035) Bumps Microsoft.Web.WebView2 from 1.0.1370.28 to 1.0.1418.22. --- updated-dependencies: - dependency-name: Microsoft.Web.WebView2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- eng/Versions.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Versions.props b/eng/Versions.props index 429e3f661897..03af952cd912 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -43,7 +43,7 @@ 3.3.3 6.0.501 4.5.0 - <_MicrosoftWebWebView2Version>1.0.1370.28 + <_MicrosoftWebWebView2Version>1.0.1418.22 <_XamarinAndroidGlideVersion>4.13.2.2 From 6728619811ea76c4e9fc14120e921a3ed079b7c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20Su=C3=A1rez?= Date: Wed, 2 Nov 2022 15:02:03 +0100 Subject: [PATCH 06/20] [iOS/macOS] Fix issue updating the Frame HasShadow property (#11055) Fixes #11025 * Added sample * Fix the issue * Added device test --- .../Pages/Compatibility/FramePage.xaml | 7 ++- .../Pages/Compatibility/FramePage.xaml.cs | 5 ++ .../Handlers/iOS/FrameRenderer.cs | 14 +++-- .../src/Core/HandlerImpl/Frame.Impl.cs | 9 +--- .../Elements/Frame/FrameTests.iOS.cs | 51 +++++++++++++++++++ 5 files changed, 74 insertions(+), 12 deletions(-) create mode 100644 src/Controls/tests/DeviceTests/Elements/Frame/FrameTests.iOS.cs diff --git a/src/Controls/samples/Controls.Sample/Pages/Compatibility/FramePage.xaml b/src/Controls/samples/Controls.Sample/Pages/Compatibility/FramePage.xaml index 013573359deb..9cd5260e9769 100644 --- a/src/Controls/samples/Controls.Sample/Pages/Compatibility/FramePage.xaml +++ b/src/Controls/samples/Controls.Sample/Pages/Compatibility/FramePage.xaml @@ -29,13 +29,18 @@