Build Information
Failed to build TestUtils with Swift 5.10 for Linux.
Build Command
bash -c docker run --rm -v "checkouts-4609320-1":/host -w "$workDir" registry.gitlab.com/finestructure/spi-images:basic-5.10-latest swift build 2>&1
Build Log
========================================
RunAll
========================================
Builder version: 4.29.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/1904labs/ios-test-utils.git
Reference: 1.0.2
Initialized empty Git repository in /host/spi-builder-workspace/.git/
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: git branch -m <name>
From https://github.com/1904labs/ios-test-utils
* tag 1.0.2 -> FETCH_HEAD
HEAD is now at a20d4cd Added example URLSession mock
Cloned https://github.com/1904labs/ios-test-utils.git
Revision (git rev-parse @):
a20d4cdea48e8ba8641941f5eb2ec983c4f0faed
SUCCESS checkout https://github.com/1904labs/ios-test-utils.git at 1.0.2
========================================
Build
========================================
Selected platform: linux
Swift version: 5.10
Building package at path: $workDir
https://github.com/1904labs/ios-test-utils.git
Running build ...
bash -c docker run --rm -v "checkouts-4609320-1":/host -w "$workDir" registry.gitlab.com/finestructure/spi-images:basic-5.10-latest swift build 2>&1
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-24593BA9C3E375BF.txt
error: emit-module command failed with exit code 1 (use -v to see invocation)
[3/5] Emitting module TestUtils
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:13:59: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
static var testURLs = [URL?: [(data: Data?, response: URLResponse?, error: Error?)]]()
^~~~~~~~~~~
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
public typealias URLResponse = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:47: error: cannot find type 'URLRequest' in scope
override class func canInit(with request: URLRequest) -> Bool {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:25: error: method does not override any method from its superclass
override class func canInit(with request: URLRequest) -> Bool {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:70: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:55: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:25: error: method does not override any method from its superclass
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:25:19: error: method does not override any method from its superclass
override func startLoading() {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:46:19: error: method does not override any method from its superclass
override func stopLoading() { }
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:7: error: only protocols can inherit from 'AnyObject'
class URLProtocolMock: URLProtocol {
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:24: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
class URLProtocolMock: URLProtocol {
^~~~~~~~~~~
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
public typealias URLProtocol = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:13:28: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
public var urlSessionMock: URLSession {
^~~~~~~~~~
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
public typealias URLSession = AnyObject
^
[4/5] Compiling TestUtils URLProtocolMock.swift
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:13:59: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
static var testURLs = [URL?: [(data: Data?, response: URLResponse?, error: Error?)]]()
^~~~~~~~~~~
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
public typealias URLResponse = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:47: error: cannot find type 'URLRequest' in scope
override class func canInit(with request: URLRequest) -> Bool {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:25: error: method does not override any method from its superclass
override class func canInit(with request: URLRequest) -> Bool {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:70: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:55: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:25: error: method does not override any method from its superclass
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:25:19: error: method does not override any method from its superclass
override func startLoading() {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:46:19: error: method does not override any method from its superclass
override func stopLoading() { }
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:7: error: only protocols can inherit from 'AnyObject'
class URLProtocolMock: URLProtocol {
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:24: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
class URLProtocolMock: URLProtocol {
^~~~~~~~~~~
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
public typealias URLProtocol = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:27:18: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocolDidFinishLoading(self)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:30:25: error: cannot find 'request' in scope
guard let url = request.url,
^~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:37:18: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocol(self, didFailWithError: error)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:39:18: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocol(self, didLoad: data)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:42:14: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocol(self, didReceive: urlResponse, cacheStoragePolicy: .allowed)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:42:86: error: cannot infer contextual base in reference to member 'allowed'
self.client?.urlProtocol(self, didReceive: urlResponse, cacheStoragePolicy: .allowed)
~^~~~~~~
[5/5] Compiling TestUtils URLSessionMock.swift
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:13:28: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
public var urlSessionMock: URLSession {
^~~~~~~~~~
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
public typealias URLSession = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:14:49: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
let configuration = URLSessionConfiguration.ephemeral
~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:16:19: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
let session = URLSession(configuration: configuration)
^~~~~~~~~~
error: fatalError
[0/1] Planning build
Building for debugging...
[0/1] Write swift-version-24593BA9C3E375BF.txt
error: emit-module command failed with exit code 1 (use -v to see invocation)
[2/4] Emitting module TestUtils
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:13:59: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
static var testURLs = [URL?: [(data: Data?, response: URLResponse?, error: Error?)]]()
^~~~~~~~~~~
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
public typealias URLResponse = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:47: error: cannot find type 'URLRequest' in scope
override class func canInit(with request: URLRequest) -> Bool {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:25: error: method does not override any method from its superclass
override class func canInit(with request: URLRequest) -> Bool {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:70: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:55: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:25: error: method does not override any method from its superclass
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:25:19: error: method does not override any method from its superclass
override func startLoading() {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:46:19: error: method does not override any method from its superclass
override func stopLoading() { }
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:7: error: only protocols can inherit from 'AnyObject'
class URLProtocolMock: URLProtocol {
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:24: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
class URLProtocolMock: URLProtocol {
^~~~~~~~~~~
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
public typealias URLProtocol = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:13:28: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
public var urlSessionMock: URLSession {
^~~~~~~~~~
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
public typealias URLSession = AnyObject
^
[3/4] Compiling TestUtils URLProtocolMock.swift
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:13:59: error: 'URLResponse' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
static var testURLs = [URL?: [(data: Data?, response: URLResponse?, error: Error?)]]()
^~~~~~~~~~~
Foundation.URLResponse:2:18: note: 'URLResponse' has been explicitly marked unavailable here
public typealias URLResponse = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:47: error: cannot find type 'URLRequest' in scope
override class func canInit(with request: URLRequest) -> Bool {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:16:25: error: method does not override any method from its superclass
override class func canInit(with request: URLRequest) -> Bool {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:70: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:55: error: cannot find type 'URLRequest' in scope
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
^~~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:21:25: error: method does not override any method from its superclass
override class func canonicalRequest(for request: URLRequest) -> URLRequest {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:25:19: error: method does not override any method from its superclass
override func startLoading() {
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:46:19: error: method does not override any method from its superclass
override func stopLoading() { }
~~~~~~~~ ^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:7: error: only protocols can inherit from 'AnyObject'
class URLProtocolMock: URLProtocol {
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:10:24: error: 'URLProtocol' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
class URLProtocolMock: URLProtocol {
^~~~~~~~~~~
Foundation.URLProtocol:2:18: note: 'URLProtocol' has been explicitly marked unavailable here
public typealias URLProtocol = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:27:18: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocolDidFinishLoading(self)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:30:25: error: cannot find 'request' in scope
guard let url = request.url,
^~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:37:18: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocol(self, didFailWithError: error)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:39:18: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocol(self, didLoad: data)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:42:14: error: value of type 'URLProtocolMock' has no member 'client'
self.client?.urlProtocol(self, didReceive: urlResponse, cacheStoragePolicy: .allowed)
~~~~ ^~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLProtocolMock.swift:42:86: error: cannot infer contextual base in reference to member 'allowed'
self.client?.urlProtocol(self, didReceive: urlResponse, cacheStoragePolicy: .allowed)
~^~~~~~~
[4/4] Compiling TestUtils URLSessionMock.swift
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:13:28: error: 'URLSession' is unavailable: This type has moved to the FoundationNetworking module. Import that module to use it.
public var urlSessionMock: URLSession {
^~~~~~~~~~
Foundation.URLSession:2:18: note: 'URLSession' has been explicitly marked unavailable here
public typealias URLSession = AnyObject
^
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:14:49: error: type 'URLSessionConfiguration' (aka 'AnyObject') has no member 'ephemeral'
let configuration = URLSessionConfiguration.ephemeral
~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~
/host/spi-builder-workspace/Sources/TestUtils/URLSessionMock.swift:16:19: error: 'URLSession' (aka 'AnyObject') cannot be constructed because it has no accessible initializers
let session = URLSession(configuration: configuration)
^~~~~~~~~~
error: fatalError
BUILD FAILURE 5.10 linux
Build Machine: Linux 2