Adjust actions log messages

This commit is contained in:
Nora
2024-01-02 13:52:08 +00:00
parent 91ab97e923
commit cfbc44311b
5 changed files with 9 additions and 9 deletions

View File

@@ -72,8 +72,8 @@ ErrorExample.args = {
<>
Request to
https://api.github.com/repos/octodemo/Hello-World/code-scanning/codeql/queries
failed. <VSCodeLink>Check logs</VSCodeLink> and try running this query
again.
failed. <VSCodeLink>View actions logs</VSCodeLink> and try running this
query again.
</>
),
};
@@ -86,7 +86,7 @@ ErrorWithButtons.args = {
"Request to https://api.github.com/repos/octodemo/Hello-World/code-scanning/codeql/queries failed. Try running this query again.",
actions: (
<>
<VSCodeButton appearance="secondary">View logs</VSCodeButton>
<VSCodeButton appearance="secondary">View actions logs</VSCodeButton>
<VSCodeButton>Retry</VSCodeButton>
</>
),

View File

@@ -34,8 +34,8 @@ const getMessage = (failureReason: VariantAnalysisFailureReason): ReactNode => {
return (
<>
The GitHub Actions workflow run has failed.{" "}
<VSCodeLink onClick={openLogs}>Check logs</VSCodeLink> and try running
this query again.
<VSCodeLink onClick={openLogs}>View actions logs</VSCodeLink> and try
running this query again.
</>
);
case VariantAnalysisFailureReason.InternalError:

View File

@@ -37,7 +37,7 @@ export const VariantAnalysisStatusStats = ({
<span>{completedAt !== undefined ? formatDate(completedAt) : "-"}</span>
)}
{onViewLogsClick && (
<VSCodeLink onClick={onViewLogsClick}>View logs</VSCodeLink>
<VSCodeLink onClick={onViewLogsClick}>View actions logs</VSCodeLink>
)}
</Container>
);

View File

@@ -147,7 +147,7 @@ describe(VariantAnalysisStats.name, () => {
completedAt: new Date(),
});
await userEvent.click(screen.getByText("View logs"));
await userEvent.click(screen.getByText("View actions logs"));
expect(onViewLogsClick).toHaveBeenCalledTimes(1);
});

View File

@@ -54,7 +54,7 @@ describe(VariantAnalysisStatusStats.name, () => {
onViewLogsClick: () => undefined,
});
expect(screen.getByText("View logs")).toBeInTheDocument();
expect(screen.getByText("View actions logs")).toBeInTheDocument();
});
it("renders when there isn't a viewLogs links", () => {
@@ -63,6 +63,6 @@ describe(VariantAnalysisStatusStats.name, () => {
onViewLogsClick: undefined,
});
expect(screen.queryByText("View logs")).not.toBeInTheDocument();
expect(screen.queryByText("View actions logs")).not.toBeInTheDocument();
});
});