diff --git a/__tests__/get-os.test.ts b/__tests__/get-os.test.ts index d30e939..da4dad9 100644 --- a/__tests__/get-os.test.ts +++ b/__tests__/get-os.test.ts @@ -8,9 +8,6 @@ describe('getOS', () => { }); test('test exception', () => { - // expect(() => { - // getOS("win32"); - // }).toThrowError("Windows is not supported"); expect(() => { getOS('centos'); }).toThrowError('centos is not supported'); diff --git a/__tests__/get-url.test.ts b/__tests__/get-url.test.ts index 118a8f2..09bffe0 100644 --- a/__tests__/get-url.test.ts +++ b/__tests__/get-url.test.ts @@ -9,14 +9,11 @@ describe('getURL()', () => { const urlMacOS = `${baseURL}/hugo_0.58.2_macOS-64bit.tar.gz`; const urlWindows = `${baseURL}/hugo_0.58.2_Windows-64bit.zip`; expect(getURL('Linux', 'false', '0.58.2')).toBe(urlLinux); + expect(getURL('Linux', 'true', '0.58.2')).not.toBe(urlLinux); + expect(getURL('MyOS', 'false', '0.58.2')).not.toBe(urlLinux); + expect(getURL('Linux', 'false', '0.58.1')).not.toBe(urlLinux); expect(getURL('Linux', 'true', '0.58.2')).toBe(urlLinuxExtended); expect(getURL('macOS', 'false', '0.58.2')).toBe(urlMacOS); expect(getURL('Windows', 'false', '0.58.2')).toBe(urlWindows); }); - - // test("test exception", () => { - // expect(() => { - // getURL("Linux", "hoge", "0.58.2"); - // }).toThrowError("Invalid input (extended): hoge"); - // }); });