Closed 304NotModified closed 2 years ago
Copying the playwright.ps1
file to the correct output folder during publish could be fixed like I have done for the node platform folders here https://github.com/microsoft/playwright-dotnet/pull/1955 by using a <ItemGroup>
instead of <Copy>
.
I left it out in the PR because you could use Microsoft.Playwright.Program.Main(new[] {" install" })
instead.
@campersau lets add it so we have the same experience for the users who publish it and they don't have to rely on the API call nor not recommended CLI for it? wdyt?
Hi,
I'm trying to run the playwright.ps1 instead of the Microsoft.Playwright.CLI.
We create an artifact of the published application (with the tests) and run that. We do something like:
dotnet publish --ouput .dist --configuration Release --no-restore)
. From that artifact we create an docker container.In the publish there is no playwright.ps1 file. I tried copying that, but it failed when running as it probably needs more files.
How could I fix that the playwright.ps1 is in my publish folder? I prefer no to create an artifact of the bin folder.
PS: we hoped we did not need the playwright.ps1 when using
-p:PlaywrightPlatform=linux
ondotnet build
. But we get sometimes, but not always, Looks like Playwright Test or Playwright was just installed or updated.