-
Notifications
You must be signed in to change notification settings - Fork 10.4k
[Templating][Components] Unify and improve E2E testing infrastructure #8188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
$InstallerPath = "$env:Temp\chrome_installer.exe"; | ||
Invoke-WebRequest "http://dl.google.com/chrome/install/375.126/chrome_installer.exe" -OutFile $InstallerPath; | ||
Start-Process -FilePath $InstallerPath -Args "/silent /install" -Verb RunAs -Wait; | ||
Remove-Item $InstallerPath |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
60 changes: 0 additions & 60 deletions
60
src/Components/test/E2ETest/Infrastructure/BrowserFixture.cs
This file was deleted.
Oops, something went wrong.
49 changes: 0 additions & 49 deletions
49
src/Components/test/E2ETest/Infrastructure/CaptureSeleniumLogsAttribute.cs
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,16 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<!-- Shared testing infrastructure for running E2E tests using selenium --> | ||
<Import Project="$(SharedSourceRoot)E2ETesting\E2ETesting.props" /> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This import and the targets import below is all that's needed to bring in Selenium E2E tests |
||
|
||
<PropertyGroup> | ||
<TargetFramework>netcoreapp3.0</TargetFramework> | ||
<DefaultItemExcludes>$(DefaultItemExcludes);node_modules\**</DefaultItemExcludes> | ||
<!-- WebDriver is not strong-named signed --> | ||
<SignAssembly>false</SignAssembly> | ||
<TestGroupName>Components.E2ETests</TestGroupName> | ||
|
||
<!-- | ||
Temporarily disabled until this runs on macOS | ||
--> | ||
<SkipTests Condition="'$(BlazorAllTests)' != 'true'">true</SkipTests> | ||
<SkipTests Condition="'$(SeleniumE2ETestsSupported)' != 'true'">true</SkipTests> | ||
<!-- https://github.com/aspnet/AspNetCore/issues/6857 --> | ||
<BuildHelixPayload>false</BuildHelixPayload> | ||
</PropertyGroup> | ||
|
@@ -18,20 +19,10 @@ | |
<Compile Include="$(SharedSourceRoot)Process\**\*.cs" LinkBase="Shared" /> | ||
</ItemGroup> | ||
|
||
<!-- Version of this SDK is set in global.json --> | ||
<Sdk Name="Yarn.MSBuild" /> | ||
|
||
<Target Name="EnsureNodeJSRestored" BeforeTargets="Build" Condition="'$(BlazorAllTests)'=='true'"> | ||
<Message Text="Running yarn install on $(MSBuildProjectFile)" Importance="High" /> | ||
<Yarn Command="install" /> | ||
</Target> | ||
|
||
<ItemGroup> | ||
<Reference Include="Microsoft.AspNetCore.Hosting" /> | ||
<Reference Include="Microsoft.AspNetCore.Server.Kestrel" /> | ||
<Reference Include="Microsoft.AspNetCore.StaticFiles" /> | ||
<Reference Include="Selenium.Support" /> | ||
<Reference Include="Selenium.WebDriver" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
|
@@ -48,4 +39,7 @@ | |
<ProjectReference Include="..\testassets\TestServer\TestServer.csproj" /> | ||
</ItemGroup> | ||
|
||
<!-- Shared testing infrastructure for running E2E tests using selenium --> | ||
<Import Project="$(SharedSourceRoot)E2ETesting\E2ETesting.targets" /> | ||
|
||
</Project> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't change
$env:Path
globally. Java is only needed in a few places.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is needed for https://github.com/aspnet/AspNetCore/pull/8188/files?utf8=%E2%9C%93&diff=unified#diff-4035093707e8bfd6d9ba2a44912dce70R9 to succeed when called as part of
yarn install
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason this is super problematic? It's only building on the CI (so local builds aren't affected) and goes away once the build finishes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not "super problematic" but it's a break from how the build currently works and broader than seemed necessary. If we go this route (rather than, say, creating a
yarn.bat
script), should clean up the Gradlew script and anything else that updates$env:Path
for Java on Windows.