SingleFile: Update a test with ni-pdbs#3381
Closed
swaroop-sridhar wants to merge 2 commits into
Closed
Conversation
The test GivenThatWeWantToPublishASingleFileApp.It_excludes_ni_pdbs_from_single_file checks for the fact that ni.pdb files are not bundled into the single-file by default. This test was expecting only the `<app>.ni.pdb` file to exist in the publish directory. However, in recent versions of the build, mscorlib.ni.pdb is also found. This commit changes the test to accomodate additional files in the publish directory.
Contributor
Author
fadimounir
reviewed
Jul 1, 2019
| GetPublishDirectory(publishCommand) | ||
| .Should() | ||
| .OnlyHaveFiles(expectedFiles); | ||
| .HaveFiles(expectedFiles); |
There was a problem hiding this comment.
Do you think it might be worth adding this check also:
foreach(file in output folder)
{
if (file == SingleFile || file == PdbFile || file == NiPdbFile)
continue;
else
Verify file.extension == ni.pdb
}
Contributor
Author
There was a problem hiding this comment.
I'm not sure it is worth tracking what .ni.pdb files are generated in this test -- it makes the test a bit fragile because of other files changing.
Also,in the long term, I don't expect the mscorlib.ni.pdb (or any other ni.pdb) to be generated everytime. So, I'd keep the change as-is for now. Once the mscorlib compilation issue is resolved, we should move back to the .OnlyHaveFiles test.
Member
|
I've included this change in #3372 so that we don't have to wait for two PRs before we snap for preview 7. So I think we can close this PR. |
Contributor
Author
|
Thanks |
Contributor
|
closing in favor of: #3372 |
dsplaisted
pushed a commit
to dsplaisted/sdk
that referenced
this pull request
Feb 19, 2020
….6 (dotnet#3381) - Microsoft.NET.Sdk - 3.1.100-preview2.19530.6
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
The test GivenThatWeWantToPublishASingleFileApp.It_excludes_ni_pdbs_from_single_file
checks for the fact that ni.pdb files are not bundled into the single-file by default.
This test was expecting only the
<app>.ni.pdbfile to exist in the publish directory.However, in recent versions of the build, mscorlib.ni.pdb is also found.
This commit changes the test to accomodate additional files in the publish directory.