Description
Expected behavior
All tests to pass, as most do on 64-bit Android platforms like AArch64 and x86_64.
Actual behavior
I'm preparing an Android SDK bundle for Swift 6, so I'm testing these new CI-generated Swift 6 multi-arch SDKs by using the instructions there along with two NIO patches, that disable some filesystem materialization code and tests that don't work on Android and add the new Android overlay where the compiler complains.
With that build and test process, all remaining tests pass on Android AArch64 and x86_64, but some segfault for armv7:
NIOCoreTests.ByteBufferTest/testExpansionOfCapacityWithPadding
NIOPosixTests.ChannelTests/testPendingWritesNoMoreThanWritevLimitIsWritten
NIOPosixTests.PendingDatagramWritesManagerTests/testPendingWritesNoMoreThanWritevLimitIsWritten
Commenting out those three tests gets all tests to run, with only one more 32-bit test failing, which I first reported four years ago in #1695:
Test Case 'HTTPHeadersTest.testCapacity' started at 2024-10-08 14:29:12.381
/home/finagolfin/swift-nio/Tests/NIOHTTP1Tests/HTTPHeadersTest.swift:394: error: HTTPHeadersTest.testCapacity : XCTAssertEqual failed: ("6") is not equal to ("5") -
Test Case 'HTTPHeadersTest.testCapacity' failed (0.0 seconds)
I build and test NIO regularly on 64-bit Android AArch64 and x86_64, but hadn't tested it on 32-bit armv7 in awhile, so some regressions crept in.
Of course, it's possible the problem lies elsewhere in the toolchain or Android support, so I then cross-compiled the swift-argument-parser
and swift-crypto
packages for Android armv7 with the 6.0.1 and latest 6.1 Sep. 25 snapshot Android SDKs linked above and all their tests passed, suggesting this issue is in NIO.
Steps to reproduce
See above
SwiftNIO version/commit hash
System & version information
Android 13 AArch64 running the Swift 6.0 and 6.1-built armv7 NIO test runner in AArch32 mode