Ios 如何测试,使用XCTest和REPL swift
有没有办法用XCTest在Swift中测试我的REPL项目 我创建了一个新的目标OSX单元测试包,将目标依赖项配置到我的项目中,并尝试使用Ios 如何测试,使用XCTest和REPL swift,ios,swift,testing,read-eval-print-loop,Ios,Swift,Testing,Read Eval Print Loop,有没有办法用XCTest在Swift中测试我的REPL项目 我创建了一个新的目标OSX单元测试包,将目标依赖项配置到我的项目中,并尝试使用 @testable import test 像这样声明类: func testPath() { let archiever = Archieves() } 我可以声明,但在构建和测试时,我得到以下错误: Undefined symbols for architecture x86_64: "test.Archieves.__allocati
@testable import test
像这样声明类:
func testPath() {
let archiever = Archieves()
}
我可以声明,但在构建和测试时,我得到以下错误:
Undefined symbols for architecture x86_64:
"test.Archieves.__allocating_init (test.Archieves.Type)() -> test.Archieves", referenced from:
testTests.testTests.testPath (testTests.testTests)() -> () in testTests.o
"type metadata accessor for test.Archieves", referenced from:
testTests.testTests.testPath (testTests.testTests)() -> () in testTests.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)