Skip to content

NIO just updated their package manifest to 5.6 and it started erroring when building the tests  #5717

@finagolfin

Description

@finagolfin

Description

@tomerd made the change in apple/swift-nio#2235 and that now causes an error on linux and Android when compiling LinuxMain.swift. Workarounds are to revert that pull or add --enable-test-discovery, which avoids compiling LinuxMain.swift.

Expected behavior

The NIO tests to build and run.

Actual behavior

This compilation error:

/home/butta/swift-nio/Tests/LinuxMain.swift:146:1: error: expressions are not allowed at the top level
(LinuxMainRunnerImpl() as LinuxMainRunner).run()

Steps to reproduce

  1. Check out swift-nio.
  2. Build the tests with swift test.

Swift Package Manager version/commit hash

5.6.2 and latest 5.7 and trunk snapshots

Swift & OS version (output of swift --version && uname -a)

Swift 5.6.2/5.7/5.8 running on Ubuntu 20.04 x86_64 or Android 12 AArch64

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions