-
Notifications
You must be signed in to change notification settings - Fork 25.3k
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
Document improved support for in memory end to end testing of MVC apps #4652
Comments
Functional testing infrastructure |
@javiercn I'll get this done. Don't sweat the sample code. I'll take care of it. I'll ping u on the PR. |
Why won't the moniker < 2.1 work for the MVC content? The new doc will be >= 2.1 and probably never need to change. |
The problem might just be training. I don't have access to the internal documents that explain conceptual versioning, and I wasn't in meetings where it was discussed/explained. Therefore, I might have significant knowledge gaps that prevent me from understanding how best to implement it in a case like this. However, everything I listed is probably* true:
probably* = I'll know more when I get into the writing. Can conceptual versioning load in an entirely different document body (i.e., from two different files)? |
@guardrex There are 3 types of conceptual versioning:
Our repo is only configured to use the Version by File Zone strategy. If we have a strong enough need for it, we can configure the repo to enable other strategies too. They can be mixed together. |
I see. Thanks for explaining it out. I'm cool on Version by File Zone. Used it ... works great outside of having to duplicate entire tables (or lists until they get that fixed). Version by File seems like it would be useful in total topic overhaul/rewrite scenarios. I'd like to just leave this current topic exactly as it is (perhaps making the sample snippets inline code) and then writing a whole new replacement topic that loads for 2.1+. I'll try to make Version by File Zone work as best I can. I have a feeling that the 2.0 MVC coverage will be Just the facts, Sir! |
@guardrex You can make that replacement doc appear only for 2.1+ by using the following metadata:
|
@scottaddie How does the file naming/TOC work in that case? |
@guardrex The single piece of metadata I provided above takes care of toggling TOC visibility automatically. This is how we handle the SignalR docs. |
I see. Cool. @Rick-Anderson I think we can cancel the meeting tomorrow. I simply didn't understand conceptual versioning. |
@scottaddie Sorry ... let me check just one more little thing on this. I can't discern how it works exactly by looking at SignalR topics (/aspnetcore/signalr) because I don't see pairs of matching topics providing alternatively-versioned content. I guess it works based on the matching UIDs. Let me give you my plan, and then you can say where I'm going right/wrong. Today, we have this ...
The metadata for integration-testing.md is ...
I'd like to add integration-testing-2-1.md here with this metadata ...
... and then ✨ The Magic Sauce™️ ✨ will take care of the rest. Is that right? |
@guardrex Your understanding is correct. The SignalR docs only apply to 2.1+, hence the reason why |
Gotcha . . thanks. I'm good. 👍 This should go well. |
@javiercn Three questions ... Question 1: Host builder signature very specficIt seems like it's very specific about the host builder signature in the SUT. Seems like I can't use ... public static IWebHost BuildWebHost(string[] args) =>
WebHost.CreateDefaultBuilder(args)
.UseStartup<Startup>()
.Build(); ... but instead need to use this ... public static IWebHostBuilder CreateWebHostBuilder(string [] args)
{
var hostBuilder = WebHost.CreateDefaultBuilder(args);
hostBuilder.UseStartup<Startup>();
return hostBuilder;
}
public static IWebHost BuildWebHost(string[] args)
{
var hostBuilder = CreateWebHostBuilder(args);
return hostBuilder.Build();
} ... yielding the method sig of
... which might be preferable because changing the SUT's Question 2: Compilation context failure?Nevermind! I see it ... aspnet/Mvc#7615. For now, I'm going to just explicitly list the packages out. At 2.1, I must return anyway to update versions ... I'll go back to the Question 3: Can the dev still supply a relative path to the SUT
Looks like there were some changes (or it was dropped) for passing a relative SUT path to the factory/fixture. What's the current way do it, if there is one? Question 4: Disable shadow copy automatically for the dev?Could ... <ItemGroup>
<Content Include="xunit.runner.json" CopyToOutputDirectory="Always" CopyToPublishDirectory="PreserveNewest" />
</ItemGroup> ... be added to the {
"shadowCopy": false
} Doesn't affect the topic here (I'll include it) ... I'm just curious if there was a reason why it wasn't done. |
@javiercn Do u have a minute to answer those questions ☝️? Question 2 isn't really a problem, and the last question is just out of curosity and doesn't affect the topic. Therefore, it's just Questions 1 and 3 that I need help with. |
@guardrex Some answers:
|
ty @javiercn
I think have what I need to finish the 1st draft. I should have it in no later than tomorrow mid-day. |
We need to cover:
The text was updated successfully, but these errors were encountered: