1
0
Fork 0
mirror of https://github.com/docker/setup-buildx-action.git synced 2025-04-22 16:06:36 +02:00

fix current context as builder name for docker driver

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax 2023-02-25 16:16:08 +01:00
parent 774ea5c2f1
commit 05ca2e6f5e
No known key found for this signature in database
GPG key ID: 3248E46B6BB8C7F7
5 changed files with 31 additions and 8 deletions

View file

@ -1,5 +1,6 @@
import {beforeEach, describe, expect, jest, test} from '@jest/globals';
import * as uuid from 'uuid';
import {Docker} from '@docker/actions-toolkit/lib/docker';
import {Toolkit} from '@docker/actions-toolkit/lib/toolkit';
import {Node} from '@docker/actions-toolkit/lib/types/builder';
@ -8,6 +9,10 @@ import * as context from '../src/context';
jest.mock('uuid');
jest.spyOn(uuid, 'v4').mockReturnValue('9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d');
jest.spyOn(Docker, 'context').mockImplementation((): Promise<string> => {
return Promise.resolve('default');
});
describe('getCreateArgs', () => {
beforeEach(() => {
process.env = Object.keys(process.env).reduce((object, key) => {