From 73ec89a09975f0abc34845203fee6c303dab43f1 Mon Sep 17 00:00:00 2001 From: Amin Yahyaabadi Date: Sun, 5 Dec 2021 09:04:06 -0600 Subject: [PATCH] test: test all the msvc version installations --- src/msvc/__tests__/msvc.test.ts | 25 ++++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/src/msvc/__tests__/msvc.test.ts b/src/msvc/__tests__/msvc.test.ts index e321286a..7d3f81a2 100644 --- a/src/msvc/__tests__/msvc.test.ts +++ b/src/msvc/__tests__/msvc.test.ts @@ -1,18 +1,33 @@ +import which from "which" import { testBin } from "../../utils/tests/test-helpers" import { setupMSVC } from "../msvc" jest.setTimeout(300000) describe("setup-msvc", () => { - it("should setup msvc", async () => { + it("should setup msvc 2019", async () => { if (process.platform !== "win32") { return } await setupMSVC("2019", "", process.arch) + await testBin("cl", []) + console.log(which("cl")) + }) - try { - await testBin("cl", []) - } catch (err) { - // TODO see #1 + it("should setup msvc 2017", async () => { + if (process.platform !== "win32") { + return } + await setupMSVC("2017", "", process.arch) + await testBin("cl", []) + console.log(which("cl")) + }) + + it("should setup msvc 2015", async () => { + if (process.platform !== "win32") { + return + } + await setupMSVC("2015", "", process.arch) + await testBin("cl", []) + console.log(which("cl")) }) })