[test] Test sendability of POSIXErrorCode

This commit is contained in:
Guillaume Lessard
2023-11-15 15:42:20 -08:00
parent fc03688e63
commit 03d9d04c2e

View File

@@ -1,4 +1,4 @@
// RUN: %target-run-simple-swift
// RUN: %target-run-simple-swift -strict-concurrency=complete
// REQUIRES: executable_test
// REQUIRES: VENDOR=apple || OS=linux-androideabi || OS=linux-android || OS=linux-gnu || OS=openbsd || OS=freebsd
// UNSUPPORTED: freestanding
@@ -18,6 +18,10 @@ import StdlibUnittest
var POSIXErrorCodeTestSuite = TestSuite("POSIXErrorCode")
// Ensure that POSIXErrorCode is actually Sendable
func send(_ value: some Sendable) {}
send(POSIXErrorCode.EPERM)
#if canImport(Darwin)
POSIXErrorCodeTestSuite.test("Darwin POSIX error codes constants") {