Skip to content

Commit

Permalink
[chore]: change dir
Browse files Browse the repository at this point in the history
  • Loading branch information
hoangtran2506 committed Jul 18, 2023
1 parent b909199 commit 726192f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
6 changes: 3 additions & 3 deletions __tests__/commands/authError.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ import {
import { dirname } from 'path';

const PROJECT_NAME = 'test-project';
const ORIGINAL_CWD = dirname('__tests__');
const TEMP_DIR = ORIGINAL_CWD + '/authErrorTemp';
const ORIGINAL_CWD = process.cwd();
const TEMP_DIR = ORIGINAL_CWD + '/__tests__/authErrorTemp';

describe('auth command: errors', () => {
let mainProgram: CommanderStatic;
Expand Down Expand Up @@ -58,7 +58,7 @@ describe('auth command: errors', () => {
});

describe('auth command: validator', () => {
test(`The name app missing -> ${ERRORS.APP_NAME_MISSING}`, () => {
test(`The name app missing -> ${dirname('__tests__')} ${ERRORS.APP_NAME_MISSING}`, () => {

Check failure on line 61 in __tests__/commands/authError.test.ts

View workflow job for this annotation

GitHub Actions / Run unit test and linter

Replace `ERRORS.APP_NAME_MISSING` with `⏎····ERRORS.APP_NAME_MISSING⏎··`
const input = '';
expect(authValidator(input)).toBe(ERRORS.APP_NAME_MISSING);
});
Expand Down
5 changes: 2 additions & 3 deletions __tests__/commands/authOptions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@ import {
initProject,
removeTempDir
} from '../test-helpers';
import { dirname } from 'path';

const PROJECT_NAME = 'test-project';
const ORIGINAL_CWD = dirname('__tests__');
const TEMP_DIR = ORIGINAL_CWD + '/authOptionsTemp';
const ORIGINAL_CWD = process.cwd();
const TEMP_DIR = ORIGINAL_CWD + '/__tests__/authOptionsTemp';
const AUTH_OPTIONS = [
'node',
'auth',
Expand Down

0 comments on commit 726192f

Please sign in to comment.