diff --git a/src/tests/add/prettier.spec.ts b/src/tests/add/prettier.spec.ts index 4d2ca48..5a58658 100644 --- a/src/tests/add/prettier.spec.ts +++ b/src/tests/add/prettier.spec.ts @@ -20,8 +20,10 @@ beforeEach(async () => { execPath = filesystem.path('/', 'tmp', tmpDirName); filesystem.dir(execPath); process.chdir(execPath); - await system.run('git config --global user.email "you@example.com"'); - await system.run('git config --global user.name "Your Name"'); + try { + await system.run('git config --global user.email "you@example.com"'); + await system.run('git config --global user.name "Your Name"'); + } catch {} }); afterEach(() => { console.log = originalLog; diff --git a/src/tests/add/tailwind.spec.ts b/src/tests/add/tailwind.spec.ts index d38e015..0f9b86c 100644 --- a/src/tests/add/tailwind.spec.ts +++ b/src/tests/add/tailwind.spec.ts @@ -20,8 +20,10 @@ beforeEach(async () => { execPath = filesystem.path('/', 'tmp', tmpDirName); filesystem.dir(execPath); process.chdir(execPath); - await system.run('git config --global user.email "you@example.com"'); - await system.run('git config --global user.name "Your Name"'); + try { + await system.run('git config --global user.email "you@example.com"'); + await system.run('git config --global user.name "Your Name"'); + } catch {} }); afterEach(() => { console.log = originalLog; diff --git a/src/utls/base-add-command.spec.ts b/src/utls/base-add-command.spec.ts index 999bc8d..ccbfec5 100644 --- a/src/utls/base-add-command.spec.ts +++ b/src/utls/base-add-command.spec.ts @@ -18,8 +18,10 @@ beforeEach(async () => { execPath = filesystem.path('/', 'tmp', tmpDirName); filesystem.dir(execPath); process.chdir(execPath); - await system.run('git config --global user.email "you@example.com"'); - await system.run('git config --global user.name "Your Name"'); + try { + await system.run('git config --global user.email "you@example.com"'); + await system.run('git config --global user.name "Your Name"'); + } catch {} }); afterEach(() => { console.log = originalLog;