From a5c43b17a95119f439540e2a8bc6d460dd288205 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Sun, 12 Jun 2022 14:30:04 -0700 Subject: [PATCH] Tests: adjust invalid character Adjust the injected character to be an invalid UTF-16 and UTF-8 character. This is required to make the tests pass on Windows. --- Tests/SystemTests/SystemStringTests.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/SystemTests/SystemStringTests.swift b/Tests/SystemTests/SystemStringTests.swift index a64e8f5..2d44593 100644 --- a/Tests/SystemTests/SystemStringTests.swift +++ b/Tests/SystemTests/SystemStringTests.swift @@ -288,7 +288,7 @@ extension SystemStringTest { source.withUnsafeBufferPointer { XCTAssertEqual(str, String(validatingPlatformString: $0.baseAddress!)) } - source[1] = CInterop.PlatformChar(truncatingIfNeeded: 0xffff) + source[1] = CInterop.PlatformChar(truncatingIfNeeded: 0xdfff) str = String(validatingPlatformString: source) XCTAssertNil(str) }