Skip to content

Test with trimming enabled in CI and in release builds. #30822

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 3 commits into from
Apr 19, 2021

Conversation

pranavkm
Copy link
Contributor

No description provided.

@pranavkm pranavkm requested a review from a team as a code owner March 10, 2021 22:54
@ghost ghost added the area-blazor Includes: Blazor, Razor Components label Mar 10, 2021
@@ -32,8 +31,7 @@ protected override string StartAndGetRootUri()
{
if (_buildWebHostMethod == null)
{
// Use Blazor's dev host server
var underlying = new DevHostServerFixture<TClientProgram>();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need to remove the devhost server fixture?

We want in general to know that things work well with our devhost server

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a rename that it's not picking up correctly?

<_Parameter1>Microsoft.AspNetCore.E2ETesting.TestTrimmedApps</_Parameter1>
<_Parameter2>$(TestTrimmedApps)</_Parameter2>
</AssemblyAttribute>
</ItemGroup>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We ought to stop doing this, it's end up adding up and becoming painful. I'm ok with it for now, but we should move to a json file or similar on the folder that is much easier to change, update, etc. without having to deal with assembly attributes

Copy link
Member

@javiercn javiercn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only minor comments, but looks good otherwise.

@TanayParikh TanayParikh changed the title Test with trimming enabeld in CI and in release builds. Test with trimming enabled in CI and in release builds. Mar 16, 2021
@@ -9,6 +9,13 @@
<GenerateResxSource>false</GenerateResxSource>
</PropertyGroup>

<PropertyGroup Condition="'$(TestTrimmedApps)' == 'true'">
<StaticWebAssetBasePath>/subdir</StaticWebAssetBasePath>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this only apply to trimmed apps?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This weirds out our in-place tests if we configure the StaticWebAssetBasePath. It's a result of how we run the test - by specifying a base path to the host. I tried changing it but it seemed like a messy ball to undo.

Btw, I'm holding off on merging this PR because it conflicts with my hot reload work. We're expressly removing a lot of the hot reload APIs during trimming which poses a problem with the approach here.

@pranavkm pranavkm force-pushed the prkrishn/trimmer-test branch from 9b222ec to 4b379dc Compare April 15, 2021 17:02
@pranavkm pranavkm force-pushed the prkrishn/trimmer-test branch from 4b379dc to 8c1cff1 Compare April 19, 2021 21:11
@pranavkm pranavkm merged commit 0b7484e into main Apr 19, 2021
@pranavkm pranavkm deleted the prkrishn/trimmer-test branch April 19, 2021 23:55
@ghost ghost added this to the 6.0-preview5 milestone Apr 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-blazor Includes: Blazor, Razor Components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants