Skip to content
Open
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
@@ -0,0 +1,41 @@
// ---------------------------------------------------------------------------
// Copyright (c) Hassan Habib & Shri Humrudha Jagathisun All rights reserved.
// Licensed under the MIT License.
// See License.txt in the project root for license information.
// ---------------------------------------------------------------------------

namespace ADotNet.Models.Pipelines.GithubPipelines.DotNets.Tasks
{
/// <summary>
/// Represents a task that installs Playwright browsers for a given project.
/// </summary>
public class InstallPlaywrightBrowsersTask : GithubTask

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Add documentation

{
private readonly string projectName;
private readonly string dotnetVersion;

/// <summary>
/// Initializes a new instance of the <see cref="InstallPlaywrightBrowsersTask"/> class.
/// </summary>
/// <param name="projectName">The name of the project for which Playwright browsers should be installed.</param>
public InstallPlaywrightBrowsersTask(
string projectName,
string dotnetVersion = "net9.0")
{
this.projectName = projectName;
this.dotnetVersion = dotnetVersion;
}
/// <summary>
/// Gets or sets the name of the task.
/// The default value is: "Install Microsoft.Playwright.CLI".
/// </summary>
public override string Name { get; set; } = "Install Microsoft.Playwright.CLI.";

/// <summary>
/// Gets the command to execute for the task.
/// The command installs Playwright browsers by running the Playwright CLI script.
/// The default value is: "pwsh ./{projectName}/bin/Debug/{dotnetVersion}/playwright.ps1 install".
/// </summary>
public override string Run => $"pwsh ./{projectName}/bin/Debug/{dotnetVersion}/playwright.ps1 install";
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// ---------------------------------------------------------------------------
// Copyright (c) Hassan Habib & Shri Humrudha Jagathisun All rights reserved.
// Licensed under the MIT License.
// See License.txt in the project root for license information.
// ---------------------------------------------------------------------------

namespace ADotNet.Models.Pipelines.GithubPipelines.DotNets.Tasks
{
public class InstallPlaywrightTask : GithubTask
{
public override string Run { get; set; } = "dotnet tool install --global Microsoft.Playwright.CLI";

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Not expecting this as we have another PR for this. Can you remove this file.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The reason is that this branche is based on other one.

}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// ---------------------------------------------------------------------------
// Copyright (c) Hassan Habib & Shri Humrudha Jagathisun All rights reserved.
// Licensed under the MIT License.
// See License.txt in the project root for license information.
// ---------------------------------------------------------------------------

namespace ADotNet.Models.Pipelines.GithubPipelines.DotNets.Tasks
{
public class WorkloadUpdateTask : GithubTask

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Not expecting this file as it is in another PR already

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The reason is that this branche is based on other one.

{
public override string Run { get; set; } = "dotnet workload update";
}
}