Skip to content

Pass template tests when project reference contains ".db" #53476

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 1 commit into from
Jan 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -69,19 +69,19 @@ private async Task BlazorWebTemplate_Core(string[] args)
if (!args.Contains(ArgConstants.IndividualAuth))
{
Assert.DoesNotContain("Microsoft.EntityFrameworkCore.Tools", projectFileContents);
Assert.DoesNotContain(".db", projectFileContents);
Assert.DoesNotContain("app.db", projectFileContents);
}
else
{
Assert.Contains("Microsoft.EntityFrameworkCore.Tools", projectFileContents);

if (args.Contains(ArgConstants.UseLocalDb))
{
Assert.DoesNotContain(".db", projectFileContents);
Assert.DoesNotContain("app.db", projectFileContents);
}
else
{
Assert.Contains(".db", projectFileContents);
Assert.Contains("app.db", projectFileContents);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ private async Task MvcTemplateCore(string languageOverride, string[] args = null

var projectExtension = languageOverride == "F#" ? "fsproj" : "csproj";
var projectFileContents = project.ReadFile($"{project.ProjectName}.{projectExtension}");
Assert.DoesNotContain(".db", projectFileContents);
Assert.DoesNotContain("app.db", projectFileContents);
Assert.DoesNotContain("Microsoft.EntityFrameworkCore.Tools", projectFileContents);
Assert.DoesNotContain("Microsoft.VisualStudio.Web.CodeGeneration.Design", projectFileContents);
Assert.DoesNotContain("Microsoft.EntityFrameworkCore.Tools.DotNet", projectFileContents);
Expand Down Expand Up @@ -164,7 +164,7 @@ private async Task MvcTemplate_IndividualAuth_Core(bool useLocalDB, bool useProg
var projectFileContents = project.ReadFile($"{project.ProjectName}.csproj");
if (!useLocalDB)
{
Assert.Contains(".db", projectFileContents);
Assert.Contains("app.db", projectFileContents);
}

await project.RunDotNetPublishAsync();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public async Task RazorPagesTemplate_NoAuth(bool useProgramMain, bool noHttps)
await project.VerifyLaunchSettings(expectedLaunchProfileNames);

var projectFileContents = ReadFile(project.TemplateOutputDir, $"{project.ProjectName}.csproj");
Assert.DoesNotContain(".db", projectFileContents);
Assert.DoesNotContain("app.db", projectFileContents);
Assert.DoesNotContain("Microsoft.EntityFrameworkCore.Tools", projectFileContents);
Assert.DoesNotContain("Microsoft.VisualStudio.Web.CodeGeneration.Design", projectFileContents);
Assert.DoesNotContain("Microsoft.EntityFrameworkCore.Tools.DotNet", projectFileContents);
Expand Down Expand Up @@ -155,7 +155,7 @@ private async Task RazorPagesTemplate_IndividualAuth_Core(bool useLocalDB, bool
var projectFileContents = ReadFile(project.TemplateOutputDir, $"{project.ProjectName}.csproj");
if (!useLocalDB)
{
Assert.Contains(".db", projectFileContents);
Assert.Contains("app.db", projectFileContents);
}

await project.RunDotNetPublishAsync();
Expand Down