Consolidate duplicate test assertions in getAvx2 tests

Co-authored-by: xhyrom <56601352+xhyrom@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-01-04 23:33:11 +00:00
parent 5748f7e69f
commit 361ded8542

View File

@ -35,14 +35,12 @@ describe("getAvx2", () => {
}); });
it("should return true by default when avx2 is not specified and not on Windows ARM64", () => { it("should return true by default when avx2 is not specified and not on Windows ARM64", () => {
// x64 architecture on various platforms
expect(getAvx2("linux", "x64")).toBe(true); expect(getAvx2("linux", "x64")).toBe(true);
expect(getAvx2("darwin", "x64")).toBe(true); expect(getAvx2("darwin", "x64")).toBe(true);
expect(getAvx2("windows", "x64")).toBe(true); expect(getAvx2("windows", "x64")).toBe(true);
expect(getAvx2("linux", "arm64")).toBe(true);
expect(getAvx2("darwin", "aarch64")).toBe(true); // ARM architecture on non-Windows platforms
});
it("should return true by default for non-Windows platforms with ARM architecture", () => {
expect(getAvx2("linux", "arm64")).toBe(true); expect(getAvx2("linux", "arm64")).toBe(true);
expect(getAvx2("linux", "aarch64")).toBe(true); expect(getAvx2("linux", "aarch64")).toBe(true);
expect(getAvx2("darwin", "arm64")).toBe(true); expect(getAvx2("darwin", "arm64")).toBe(true);