Fix tests that now require await
This commit is contained in:
@@ -56,7 +56,7 @@ const actionMetadata = {
|
||||
};
|
||||
|
||||
it("returns default context when job is undefined", async () => {
|
||||
const workflowContext = createWorkflowContext(workflow, undefined);
|
||||
const workflowContext = await createWorkflowContext(workflow, undefined);
|
||||
const defaultContext = getDefaultStepsContext(workflowContext);
|
||||
|
||||
const stepsContext = await getStepsContext(new Octokit(), new TTLCache(), defaultContext, workflowContext);
|
||||
@@ -68,7 +68,7 @@ it("adds action outputs", async () => {
|
||||
.sandbox()
|
||||
.getOnce("https://api.github.com/repos/actions/cache/contents/action.yml?ref=v3", actionMetadata);
|
||||
|
||||
const workflowContext = createWorkflowContext(workflow, "build");
|
||||
const workflowContext = await createWorkflowContext(workflow, "build");
|
||||
const defaultContext = getDefaultStepsContext(workflowContext);
|
||||
|
||||
const stepsContext = await getStepsContext(
|
||||
|
||||
@@ -60,7 +60,7 @@ const actionMetadata = {
|
||||
};
|
||||
|
||||
async function getDescription(input: string, mock: fetchMock.FetchMockSandbox) {
|
||||
const workflowContext = createWorkflowContext(workflow, "build", 0);
|
||||
const workflowContext = await createWorkflowContext(workflow, "build", 0);
|
||||
|
||||
return await getActionInputDescription(
|
||||
new Octokit({
|
||||
|
||||
Reference in New Issue
Block a user