diff --git a/.gitignore b/.gitignore index d3941ec..422fad7 100644 --- a/.gitignore +++ b/.gitignore @@ -43,7 +43,6 @@ Pods/ # Add this line if you want to avoid checking in source code from Carthage dependencies. # Carthage/Checkouts -Carthage/Build ### Objective-C ### @@ -172,3 +171,4 @@ crashlytics-build.properties Examples/Rome/ TestPackage/.build .build/ +SwiftlineTests/Carthage/Checkouts \ No newline at end of file diff --git a/Swiftline.xcodeproj/Configs/Project.xcconfig b/Swiftline.xcodeproj/Configs/Project.xcconfig new file mode 100644 index 0000000..5f63024 --- /dev/null +++ b/Swiftline.xcodeproj/Configs/Project.xcconfig @@ -0,0 +1,7 @@ +PRODUCT_NAME = $(TARGET_NAME) +SUPPORTED_PLATFORMS = macosx iphoneos iphonesimulator appletvos appletvsimulator watchos watchsimulator +MACOSX_DEPLOYMENT_TARGET = 10.10 +DYLIB_INSTALL_NAME_BASE = @rpath +OTHER_SWIFT_FLAGS = -DXcode +COMBINE_HIDPI_IMAGES = YES +USE_HEADERMAP = NO diff --git a/Swiftline.xcodeproj/Swiftline_Info.plist b/Swiftline.xcodeproj/Swiftline_Info.plist new file mode 100644 index 0000000..57ada9f --- /dev/null +++ b/Swiftline.xcodeproj/Swiftline_Info.plist @@ -0,0 +1,25 @@ + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + $(CURRENT_PROJECT_VERSION) + NSPrincipalClass + + + diff --git a/Swiftline.xcodeproj/project.pbxproj b/Swiftline.xcodeproj/project.pbxproj new file mode 100644 index 0000000..618abca --- /dev/null +++ b/Swiftline.xcodeproj/project.pbxproj @@ -0,0 +1,314 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + __src_cc_ref_Source/Agree.swift /* Agree.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Agree.swift /* Agree.swift */; }; + __src_cc_ref_Source/AgreeSettings.swift /* AgreeSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/AgreeSettings.swift /* AgreeSettings.swift */; }; + __src_cc_ref_Source/ArgConvertible.swift /* ArgConvertible.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/ArgConvertible.swift /* ArgConvertible.swift */; }; + __src_cc_ref_Source/Args.swift /* Args.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Args.swift /* Args.swift */; }; + __src_cc_ref_Source/ArgsParser.swift /* ArgsParser.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/ArgsParser.swift /* ArgsParser.swift */; }; + __src_cc_ref_Source/Argument.swift /* Argument.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Argument.swift /* Argument.swift */; }; + __src_cc_ref_Source/Ask.swift /* Ask.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Ask.swift /* Ask.swift */; }; + __src_cc_ref_Source/AskSettings.swift /* AskSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/AskSettings.swift /* AskSettings.swift */; }; + __src_cc_ref_Source/AskerValidator.swift /* AskerValidator.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/AskerValidator.swift /* AskerValidator.swift */; }; + __src_cc_ref_Source/Choose.swift /* Choose.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Choose.swift /* Choose.swift */; }; + __src_cc_ref_Source/ChooseSettings.swift /* ChooseSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/ChooseSettings.swift /* ChooseSettings.swift */; }; + __src_cc_ref_Source/Colorizer.swift /* Colorizer.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Colorizer.swift /* Colorizer.swift */; }; + __src_cc_ref_Source/CommandExecutor.swift /* CommandExecutor.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/CommandExecutor.swift /* CommandExecutor.swift */; }; + __src_cc_ref_Source/Env.swift /* Env.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Env.swift /* Env.swift */; }; + __src_cc_ref_Source/Glob.swift /* Glob.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Glob.swift /* Glob.swift */; }; + __src_cc_ref_Source/ProcessInfo.swift /* ProcessInfo.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/ProcessInfo.swift /* ProcessInfo.swift */; }; + __src_cc_ref_Source/PromptPrinter.swift /* PromptPrinter.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/PromptPrinter.swift /* PromptPrinter.swift */; }; + __src_cc_ref_Source/PromptReader.swift /* PromptReader.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/PromptReader.swift /* PromptReader.swift */; }; + __src_cc_ref_Source/PromptSettings.swift /* PromptSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/PromptSettings.swift /* PromptSettings.swift */; }; + __src_cc_ref_Source/RunResults.swift /* RunResults.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/RunResults.swift /* RunResults.swift */; }; + __src_cc_ref_Source/Runner.swift /* Runner.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/Runner.swift /* Runner.swift */; }; + __src_cc_ref_Source/RunnerSettings.swift /* RunnerSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/RunnerSettings.swift /* RunnerSettings.swift */; }; + __src_cc_ref_Source/ShortHandRunner.swift /* ShortHandRunner.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/ShortHandRunner.swift /* ShortHandRunner.swift */; }; + __src_cc_ref_Source/StringBackgroundColorizer.swift /* StringBackgroundColorizer.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/StringBackgroundColorizer.swift /* StringBackgroundColorizer.swift */; }; + __src_cc_ref_Source/StringForegroundColorizer.swift /* StringForegroundColorizer.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/StringForegroundColorizer.swift /* StringForegroundColorizer.swift */; }; + __src_cc_ref_Source/StringStyle.swift /* StringStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/StringStyle.swift /* StringStyle.swift */; }; + __src_cc_ref_Source/StringStyleColorizer.swift /* StringStyleColorizer.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/StringStyleColorizer.swift /* StringStyleColorizer.swift */; }; + __src_cc_ref_Source/TaskPipe.swift /* TaskPipe.swift in Sources */ = {isa = PBXBuildFile; fileRef = __PBXFileRef_Source/TaskPipe.swift /* TaskPipe.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + __PBXFileRef_Package.swift /* Package.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Package.swift; sourceTree = ""; }; + __PBXFileRef_Source/Agree.swift /* Agree.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Agree.swift; sourceTree = ""; }; + __PBXFileRef_Source/AgreeSettings.swift /* AgreeSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AgreeSettings.swift; sourceTree = ""; }; + __PBXFileRef_Source/ArgConvertible.swift /* ArgConvertible.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArgConvertible.swift; sourceTree = ""; }; + __PBXFileRef_Source/Args.swift /* Args.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Args.swift; sourceTree = ""; }; + __PBXFileRef_Source/ArgsParser.swift /* ArgsParser.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArgsParser.swift; sourceTree = ""; }; + __PBXFileRef_Source/Argument.swift /* Argument.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Argument.swift; sourceTree = ""; }; + __PBXFileRef_Source/Ask.swift /* Ask.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Ask.swift; sourceTree = ""; }; + __PBXFileRef_Source/AskSettings.swift /* AskSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AskSettings.swift; sourceTree = ""; }; + __PBXFileRef_Source/AskerValidator.swift /* AskerValidator.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AskerValidator.swift; sourceTree = ""; }; + __PBXFileRef_Source/Choose.swift /* Choose.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Choose.swift; sourceTree = ""; }; + __PBXFileRef_Source/ChooseSettings.swift /* ChooseSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ChooseSettings.swift; sourceTree = ""; }; + __PBXFileRef_Source/Colorizer.swift /* Colorizer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Colorizer.swift; sourceTree = ""; }; + __PBXFileRef_Source/CommandExecutor.swift /* CommandExecutor.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CommandExecutor.swift; sourceTree = ""; }; + __PBXFileRef_Source/Env.swift /* Env.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Env.swift; sourceTree = ""; }; + __PBXFileRef_Source/Glob.swift /* Glob.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Glob.swift; sourceTree = ""; }; + __PBXFileRef_Source/ProcessInfo.swift /* ProcessInfo.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ProcessInfo.swift; sourceTree = ""; }; + __PBXFileRef_Source/PromptPrinter.swift /* PromptPrinter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PromptPrinter.swift; sourceTree = ""; }; + __PBXFileRef_Source/PromptReader.swift /* PromptReader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PromptReader.swift; sourceTree = ""; }; + __PBXFileRef_Source/PromptSettings.swift /* PromptSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PromptSettings.swift; sourceTree = ""; }; + __PBXFileRef_Source/RunResults.swift /* RunResults.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RunResults.swift; sourceTree = ""; }; + __PBXFileRef_Source/Runner.swift /* Runner.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Runner.swift; sourceTree = ""; }; + __PBXFileRef_Source/RunnerSettings.swift /* RunnerSettings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RunnerSettings.swift; sourceTree = ""; }; + __PBXFileRef_Source/ShortHandRunner.swift /* ShortHandRunner.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ShortHandRunner.swift; sourceTree = ""; }; + __PBXFileRef_Source/StringBackgroundColorizer.swift /* StringBackgroundColorizer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringBackgroundColorizer.swift; sourceTree = ""; }; + __PBXFileRef_Source/StringForegroundColorizer.swift /* StringForegroundColorizer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringForegroundColorizer.swift; sourceTree = ""; }; + __PBXFileRef_Source/StringStyle.swift /* StringStyle.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringStyle.swift; sourceTree = ""; }; + __PBXFileRef_Source/StringStyleColorizer.swift /* StringStyleColorizer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StringStyleColorizer.swift; sourceTree = ""; }; + __PBXFileRef_Source/TaskPipe.swift /* TaskPipe.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TaskPipe.swift; sourceTree = ""; }; + __PBXFileRef_Swiftline.xcodeproj/Configs/Project.xcconfig /* Swiftline.xcodeproj/Configs/Project.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Swiftline.xcodeproj/Configs/Project.xcconfig; sourceTree = ""; }; + "_____Product_Swiftline" /* Swiftline.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = Swiftline.framework; sourceTree = BUILT_PRODUCTS_DIR; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + "___LinkPhase_Swiftline" /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 0; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + "___RootGroup_" = { + isa = PBXGroup; + children = ( + __PBXFileRef_Package.swift /* Package.swift */, + "_____Configs_" /* Configs */, + "_____Sources_" /* Sources */, + "____Products_" /* Products */, + ); + sourceTree = ""; + }; + "____Products_" /* Products */ = { + isa = PBXGroup; + children = ( + "_____Product_Swiftline" /* Swiftline.framework */, + ); + name = Products; + sourceTree = ""; + }; + "_____Configs_" /* Configs */ = { + isa = PBXGroup; + children = ( + __PBXFileRef_Swiftline.xcodeproj/Configs/Project.xcconfig /* Swiftline.xcodeproj/Configs/Project.xcconfig */, + ); + name = Configs; + sourceTree = ""; + }; + "_____Sources_" /* Sources */ = { + isa = PBXGroup; + children = ( + "_______Group_Swiftline" /* Swiftline */, + ); + name = Sources; + sourceTree = ""; + }; + "_______Group_Swiftline" /* Swiftline */ = { + isa = PBXGroup; + children = ( + __PBXFileRef_Source/Agree.swift /* Agree.swift */, + __PBXFileRef_Source/AgreeSettings.swift /* AgreeSettings.swift */, + __PBXFileRef_Source/ArgConvertible.swift /* ArgConvertible.swift */, + __PBXFileRef_Source/Args.swift /* Args.swift */, + __PBXFileRef_Source/ArgsParser.swift /* ArgsParser.swift */, + __PBXFileRef_Source/Argument.swift /* Argument.swift */, + __PBXFileRef_Source/Ask.swift /* Ask.swift */, + __PBXFileRef_Source/AskerValidator.swift /* AskerValidator.swift */, + __PBXFileRef_Source/AskSettings.swift /* AskSettings.swift */, + __PBXFileRef_Source/Choose.swift /* Choose.swift */, + __PBXFileRef_Source/ChooseSettings.swift /* ChooseSettings.swift */, + __PBXFileRef_Source/Colorizer.swift /* Colorizer.swift */, + __PBXFileRef_Source/CommandExecutor.swift /* CommandExecutor.swift */, + __PBXFileRef_Source/Env.swift /* Env.swift */, + __PBXFileRef_Source/Glob.swift /* Glob.swift */, + __PBXFileRef_Source/ProcessInfo.swift /* ProcessInfo.swift */, + __PBXFileRef_Source/PromptPrinter.swift /* PromptPrinter.swift */, + __PBXFileRef_Source/PromptReader.swift /* PromptReader.swift */, + __PBXFileRef_Source/PromptSettings.swift /* PromptSettings.swift */, + __PBXFileRef_Source/Runner.swift /* Runner.swift */, + __PBXFileRef_Source/RunnerSettings.swift /* RunnerSettings.swift */, + __PBXFileRef_Source/RunResults.swift /* RunResults.swift */, + __PBXFileRef_Source/ShortHandRunner.swift /* ShortHandRunner.swift */, + __PBXFileRef_Source/StringBackgroundColorizer.swift /* StringBackgroundColorizer.swift */, + __PBXFileRef_Source/StringForegroundColorizer.swift /* StringForegroundColorizer.swift */, + __PBXFileRef_Source/StringStyle.swift /* StringStyle.swift */, + __PBXFileRef_Source/StringStyleColorizer.swift /* StringStyleColorizer.swift */, + __PBXFileRef_Source/TaskPipe.swift /* TaskPipe.swift */, + ); + name = Swiftline; + path = Source; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + "______Target_Swiftline" /* Swiftline */ = { + isa = PBXNativeTarget; + buildConfigurationList = "_______Confs_Swiftline" /* Build configuration list for PBXNativeTarget "Swiftline" */; + buildPhases = ( + CompilePhase_Swiftline /* Sources */, + "___LinkPhase_Swiftline" /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Swiftline; + productName = Swiftline; + productReference = "_____Product_Swiftline" /* Swiftline.framework */; + productType = "com.apple.product-type.framework"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + __RootObject_ /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 9999; + TargetAttributes = { + "______Target_Swiftline" = { + LastSwiftMigration = 0800; + }; + }; + }; + buildConfigurationList = "___RootConfs_" /* Build configuration list for PBXProject "Swiftline" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = "___RootGroup_"; + productRefGroup = "____Products_" /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + "______Target_Swiftline" /* Swiftline */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXSourcesBuildPhase section */ + CompilePhase_Swiftline /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 0; + files = ( + __src_cc_ref_Source/Agree.swift /* Agree.swift in Sources */, + __src_cc_ref_Source/AgreeSettings.swift /* AgreeSettings.swift in Sources */, + __src_cc_ref_Source/ArgConvertible.swift /* ArgConvertible.swift in Sources */, + __src_cc_ref_Source/Args.swift /* Args.swift in Sources */, + __src_cc_ref_Source/ArgsParser.swift /* ArgsParser.swift in Sources */, + __src_cc_ref_Source/Argument.swift /* Argument.swift in Sources */, + __src_cc_ref_Source/Ask.swift /* Ask.swift in Sources */, + __src_cc_ref_Source/AskerValidator.swift /* AskerValidator.swift in Sources */, + __src_cc_ref_Source/AskSettings.swift /* AskSettings.swift in Sources */, + __src_cc_ref_Source/Choose.swift /* Choose.swift in Sources */, + __src_cc_ref_Source/ChooseSettings.swift /* ChooseSettings.swift in Sources */, + __src_cc_ref_Source/Colorizer.swift /* Colorizer.swift in Sources */, + __src_cc_ref_Source/CommandExecutor.swift /* CommandExecutor.swift in Sources */, + __src_cc_ref_Source/Env.swift /* Env.swift in Sources */, + __src_cc_ref_Source/Glob.swift /* Glob.swift in Sources */, + __src_cc_ref_Source/ProcessInfo.swift /* ProcessInfo.swift in Sources */, + __src_cc_ref_Source/PromptPrinter.swift /* PromptPrinter.swift in Sources */, + __src_cc_ref_Source/PromptReader.swift /* PromptReader.swift in Sources */, + __src_cc_ref_Source/PromptSettings.swift /* PromptSettings.swift in Sources */, + __src_cc_ref_Source/Runner.swift /* Runner.swift in Sources */, + __src_cc_ref_Source/RunnerSettings.swift /* RunnerSettings.swift in Sources */, + __src_cc_ref_Source/RunResults.swift /* RunResults.swift in Sources */, + __src_cc_ref_Source/ShortHandRunner.swift /* ShortHandRunner.swift in Sources */, + __src_cc_ref_Source/StringBackgroundColorizer.swift /* StringBackgroundColorizer.swift in Sources */, + __src_cc_ref_Source/StringForegroundColorizer.swift /* StringForegroundColorizer.swift in Sources */, + __src_cc_ref_Source/StringStyle.swift /* StringStyle.swift in Sources */, + __src_cc_ref_Source/StringStyleColorizer.swift /* StringStyleColorizer.swift in Sources */, + __src_cc_ref_Source/TaskPipe.swift /* TaskPipe.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin XCBuildConfiguration section */ + _ReleaseConf_Swiftline /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ENABLE_TESTABILITY = YES; + FRAMEWORK_SEARCH_PATHS = "$(PLATFORM_DIR)/Developer/Library/Frameworks"; + INFOPLIST_FILE = Swiftline.xcodeproj/Swiftline_Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(TOOLCHAIN_DIR)/usr/lib/swift/macosx"; + OTHER_LDFLAGS = "$(inherited)"; + OTHER_SWIFT_FLAGS = "$(inherited)"; + PRODUCT_BUNDLE_IDENTIFIER = Swiftline; + PRODUCT_MODULE_NAME = "$(TARGET_NAME:c99extidentifier)"; + PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)"; + SWIFT_VERSION = 3.0; + }; + name = Release; + }; + "___DebugConf_Swiftline" /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ENABLE_TESTABILITY = YES; + FRAMEWORK_SEARCH_PATHS = "$(PLATFORM_DIR)/Developer/Library/Frameworks"; + INFOPLIST_FILE = Swiftline.xcodeproj/Swiftline_Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(TOOLCHAIN_DIR)/usr/lib/swift/macosx"; + OTHER_LDFLAGS = "$(inherited)"; + OTHER_SWIFT_FLAGS = "$(inherited)"; + PRODUCT_BUNDLE_IDENTIFIER = Swiftline; + PRODUCT_MODULE_NAME = "$(TARGET_NAME:c99extidentifier)"; + PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 3.0; + }; + name = Debug; + }; + "_____Release_" /* Release */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = __PBXFileRef_Swiftline.xcodeproj/Configs/Project.xcconfig /* Swiftline.xcodeproj/Configs/Project.xcconfig */; + buildSettings = { + }; + name = Release; + }; + "_______Debug_" /* Debug */ = { + isa = XCBuildConfiguration; + baseConfigurationReference = __PBXFileRef_Swiftline.xcodeproj/Configs/Project.xcconfig /* Swiftline.xcodeproj/Configs/Project.xcconfig */; + buildSettings = { + }; + name = Debug; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + "___RootConfs_" /* Build configuration list for PBXProject "Swiftline" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + "_______Debug_" /* Debug */, + "_____Release_" /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; + "_______Confs_Swiftline" /* Build configuration list for PBXNativeTarget "Swiftline" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + "___DebugConf_Swiftline" /* Debug */, + _ReleaseConf_Swiftline /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Debug; + }; +/* End XCConfigurationList section */ + }; + rootObject = __RootObject_ /* Project object */; +} diff --git a/Swiftline.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/Swiftline.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..919434a --- /dev/null +++ b/Swiftline.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/Swiftline.xcodeproj/xcshareddata/xcschemes/Swiftline.xcscheme b/Swiftline.xcodeproj/xcshareddata/xcschemes/Swiftline.xcscheme new file mode 100644 index 0000000..e5bbd68 --- /dev/null +++ b/Swiftline.xcodeproj/xcshareddata/xcschemes/Swiftline.xcscheme @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Swiftline.xcodeproj/xcshareddata/xcschemes/xcschememanagement.plist b/Swiftline.xcodeproj/xcshareddata/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..c85c6da --- /dev/null +++ b/Swiftline.xcodeproj/xcshareddata/xcschemes/xcschememanagement.plist @@ -0,0 +1,12 @@ + + + + SchemeUserState + + Swiftline.xcscheme + + + SuppressBuildableAutocreation + + + diff --git a/SwiftlineTests/.ruby-version b/SwiftlineTests/.ruby-version new file mode 100644 index 0000000..399088b --- /dev/null +++ b/SwiftlineTests/.ruby-version @@ -0,0 +1 @@ +2.1.6 diff --git a/SwiftlineTests/Cartfile b/SwiftlineTests/Cartfile new file mode 100644 index 0000000..e95f845 --- /dev/null +++ b/SwiftlineTests/Cartfile @@ -0,0 +1,2 @@ +github "Quick/Quick" +github "Quick/Nimble" \ No newline at end of file diff --git a/SwiftlineTests/Cartfile.resolved b/SwiftlineTests/Cartfile.resolved new file mode 100644 index 0000000..06a76c1 --- /dev/null +++ b/SwiftlineTests/Cartfile.resolved @@ -0,0 +1,2 @@ +github "Quick/Nimble" "v5.0.0" +github "Quick/Quick" "v0.10.0" diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework.dSYM/Contents/Info.plist b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..fb341f1 --- /dev/null +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.net.jeffhui.Nimble + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework.dSYM/Contents/Resources/DWARF/Nimble b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework.dSYM/Contents/Resources/DWARF/Nimble new file mode 100644 index 0000000..54591ce Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework.dSYM/Contents/Resources/DWARF/Nimble differ diff --git a/SwiftlineTests/Rome/Nimble.framework/Headers b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Headers similarity index 100% rename from SwiftlineTests/Rome/Nimble.framework/Headers rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Headers diff --git a/SwiftlineTests/Rome/Nimble.framework/Modules b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Modules similarity index 100% rename from SwiftlineTests/Rome/Nimble.framework/Modules rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Modules diff --git a/SwiftlineTests/Rome/Nimble.framework/Nimble b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Nimble similarity index 100% rename from SwiftlineTests/Rome/Nimble.framework/Nimble rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Nimble diff --git a/SwiftlineTests/Rome/Nimble.framework/Resources b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Resources similarity index 100% rename from SwiftlineTests/Rome/Nimble.framework/Resources rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Resources diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/DSL.h b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/DSL.h similarity index 93% rename from SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/DSL.h rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/DSL.h index 5ec3b51..a499059 100644 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/DSL.h +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/DSL.h @@ -53,6 +53,10 @@ NIMBLE_EXPORT id NMB_beIdenticalTo(id expectedInstance); NIMBLE_SHORT(id beIdenticalTo(id expectedInstance), NMB_beIdenticalTo(expectedInstance)); +NIMBLE_EXPORT id NMB_be(id expectedInstance); +NIMBLE_SHORT(id be(id expectedInstance), + NMB_be(expectedInstance)); + NIMBLE_EXPORT id NMB_beLessThan(NSNumber *expectedValue); NIMBLE_SHORT(id beLessThan(NSNumber *expectedValue), NMB_beLessThan(expectedValue)); @@ -107,6 +111,12 @@ NIMBLE_EXPORT id NMB_allPass(id matcher); NIMBLE_SHORT(id allPass(id matcher), NMB_allPass(matcher)); +NIMBLE_EXPORT id NMB_satisfyAnyOfWithMatchers(id matchers); +#define NMB_satisfyAnyOf(...) NMB_satisfyAnyOfWithMatchers(@[__VA_ARGS__]) +#ifndef NIMBLE_DISABLE_SHORT_SYNTAX +#define satisfyAnyOf(...) NMB_satisfyAnyOf(__VA_ARGS__) +#endif + // In order to preserve breakpoint behavior despite using macros to fill in __FILE__ and __LINE__, // define a builder that populates __FILE__ and __LINE__, and returns a block that takes timeout // and action arguments. See https://github.com/Quick/Quick/pull/185 for details. diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/NMBExceptionCapture.h b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/NMBExceptionCapture.h new file mode 100644 index 0000000..e0ec05a --- /dev/null +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/NMBExceptionCapture.h @@ -0,0 +1,11 @@ +#import +#import + +@interface NMBExceptionCapture : NSObject + +- (nonnull instancetype)initWithHandler:(void(^ _Nullable)(NSException * _Nonnull))handler finally:(void(^ _Nullable)())finally; +- (void)tryBlock:(void(^ _Nonnull)())unsafeBlock NS_SWIFT_NAME(tryBlock(_:)); + +@end + +typedef void(^NMBSourceCallbackBlock)(BOOL successful); diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/NMBStringify.h b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/NMBStringify.h new file mode 100644 index 0000000..e5d5ddd --- /dev/null +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/NMBStringify.h @@ -0,0 +1,18 @@ +@class NSString; + +/** + * Returns a string appropriate for displaying in test output + * from the provided value. + * + * @param value A value that will show up in a test's output. + * + * @return The string that is returned can be + * customized per type by conforming a type to the `TestOutputStringConvertible` + * protocol. When stringifying a non-`TestOutputStringConvertible` type, this + * function will return the value's debug description and then its + * normal description if available and in that order. Otherwise it + * will return the result of constructing a string from the value. + * + * @see `TestOutputStringConvertible` + */ +extern NSString *_Nonnull NMBStringify(id _Nullable anyObject) __attribute__((warn_unused_result)); diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/Nimble-Swift.h b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/Nimble-Swift.h new file mode 100644 index 0000000..7afe81d --- /dev/null +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/Nimble-Swift.h @@ -0,0 +1,433 @@ +// Generated by Apple Swift version 3.0 (swiftlang-800.0.46.2 clang-800.0.38) +#pragma clang diagnostic push + +#if defined(__has_include) && __has_include() +# include +#endif + +#pragma clang diagnostic ignored "-Wauto-import" +#include +#include +#include +#include + +#if !defined(SWIFT_TYPEDEFS) +# define SWIFT_TYPEDEFS 1 +# if defined(__has_include) && __has_include() +# include +# elif !defined(__cplusplus) || __cplusplus < 201103L +typedef uint_least16_t char16_t; +typedef uint_least32_t char32_t; +# endif +typedef float swift_float2 __attribute__((__ext_vector_type__(2))); +typedef float swift_float3 __attribute__((__ext_vector_type__(3))); +typedef float swift_float4 __attribute__((__ext_vector_type__(4))); +typedef double swift_double2 __attribute__((__ext_vector_type__(2))); +typedef double swift_double3 __attribute__((__ext_vector_type__(3))); +typedef double swift_double4 __attribute__((__ext_vector_type__(4))); +typedef int swift_int2 __attribute__((__ext_vector_type__(2))); +typedef int swift_int3 __attribute__((__ext_vector_type__(3))); +typedef int swift_int4 __attribute__((__ext_vector_type__(4))); +typedef unsigned int swift_uint2 __attribute__((__ext_vector_type__(2))); +typedef unsigned int swift_uint3 __attribute__((__ext_vector_type__(3))); +typedef unsigned int swift_uint4 __attribute__((__ext_vector_type__(4))); +#endif + +#if !defined(SWIFT_PASTE) +# define SWIFT_PASTE_HELPER(x, y) x##y +# define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y) +#endif +#if !defined(SWIFT_METATYPE) +# define SWIFT_METATYPE(X) Class +#endif +#if !defined(SWIFT_CLASS_PROPERTY) +# if __has_feature(objc_class_property) +# define SWIFT_CLASS_PROPERTY(...) __VA_ARGS__ +# else +# define SWIFT_CLASS_PROPERTY(...) +# endif +#endif + +#if defined(__has_attribute) && __has_attribute(objc_runtime_name) +# define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X))) +#else +# define SWIFT_RUNTIME_NAME(X) +#endif +#if defined(__has_attribute) && __has_attribute(swift_name) +# define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X))) +#else +# define SWIFT_COMPILE_NAME(X) +#endif +#if defined(__has_attribute) && __has_attribute(objc_method_family) +# define SWIFT_METHOD_FAMILY(X) __attribute__((objc_method_family(X))) +#else +# define SWIFT_METHOD_FAMILY(X) +#endif +#if !defined(SWIFT_CLASS_EXTRA) +# define SWIFT_CLASS_EXTRA +#endif +#if !defined(SWIFT_PROTOCOL_EXTRA) +# define SWIFT_PROTOCOL_EXTRA +#endif +#if !defined(SWIFT_ENUM_EXTRA) +# define SWIFT_ENUM_EXTRA +#endif +#if !defined(SWIFT_CLASS) +# if defined(__has_attribute) && __has_attribute(objc_subclassing_restricted) +# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA +# define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA +# else +# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA +# define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA +# endif +#endif + +#if !defined(SWIFT_PROTOCOL) +# define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA +# define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA +#endif + +#if !defined(SWIFT_EXTENSION) +# define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__) +#endif + +#if !defined(OBJC_DESIGNATED_INITIALIZER) +# if defined(__has_attribute) && __has_attribute(objc_designated_initializer) +# define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer)) +# else +# define OBJC_DESIGNATED_INITIALIZER +# endif +#endif +#if !defined(SWIFT_ENUM) +# define SWIFT_ENUM(_type, _name) enum _name : _type _name; enum SWIFT_ENUM_EXTRA _name : _type +# if defined(__has_feature) && __has_feature(generalized_swift_name) +# define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME) enum _name : _type _name SWIFT_COMPILE_NAME(SWIFT_NAME); enum SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_ENUM_EXTRA _name : _type +# else +# define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME) SWIFT_ENUM(_type, _name) +# endif +#endif +#if !defined(SWIFT_UNAVAILABLE) +# define SWIFT_UNAVAILABLE __attribute__((unavailable)) +#endif +#if defined(__has_feature) && __has_feature(modules) +@import ObjectiveC; +@import Foundation; +#endif + +#pragma clang diagnostic ignored "-Wproperty-attribute-mismatch" +#pragma clang diagnostic ignored "-Wduplicate-method-arg" + +/** + Encapsulates the failure message that matchers can report to the end user. + This is shared state between Nimble and matchers that mutate this value. +*/ +SWIFT_CLASS("_TtC6Nimble14FailureMessage") +@interface FailureMessage : NSObject +@property (nonatomic, copy) NSString * _Nonnull expected; +@property (nonatomic, copy) NSString * _Nullable actualValue; +@property (nonatomic, copy) NSString * _Nonnull to; +@property (nonatomic, copy) NSString * _Nonnull postfixMessage; +@property (nonatomic, copy) NSString * _Nonnull postfixActual; +/** + An optional message that will be appended as a new line and provides additional details + about the failure. This message will only be visible in the issue navigator / in logs but + not directly in the source editor since only a single line is presented there. +*/ +@property (nonatomic, copy) NSString * _Nullable extendedMessage; +@property (nonatomic, copy) NSString * _Nullable userDescription; +@property (nonatomic, copy) NSString * _Nonnull stringValue; +- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; +- (nonnull instancetype)initWithStringValue:(NSString * _Nonnull)stringValue OBJC_DESIGNATED_INITIALIZER; +@end + + +/** + Protocol for types that support only beEmpty(), haveCount() matchers +*/ +SWIFT_PROTOCOL("_TtP6Nimble13NMBCollection_") +@protocol NMBCollection +@property (nonatomic, readonly) NSInteger count; +@end + + +SWIFT_PROTOCOL("_TtP6Nimble13NMBComparable_") +@protocol NMBComparable +- (NSComparisonResult)NMB_compare:(id _Null_unspecified)otherObject; +@end + + +/** + Protocol for types that support contain() matcher. +*/ +SWIFT_PROTOCOL("_TtP6Nimble12NMBContainer_") +@protocol NMBContainer +- (BOOL)containsObject:(id _Nonnull)anObject; +@end + +@protocol NMBMatcher; + +SWIFT_CLASS("_TtC6Nimble14NMBExpectation") +@interface NMBExpectation : NSObject +- (nonnull instancetype)initWithActualBlock:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock negative:(BOOL)negative file:(NSString * _Nonnull)file line:(NSUInteger)line OBJC_DESIGNATED_INITIALIZER; +@property (nonatomic, readonly, copy) NMBExpectation * _Nonnull (^ _Nonnull withTimeout)(NSTimeInterval); +@property (nonatomic, readonly, copy) void (^ _Nonnull to)(id _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toWithDescription)(id _Nonnull, NSString * _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toNot)(id _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toNotWithDescription)(id _Nonnull, NSString * _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull notTo)(id _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull notToWithDescription)(id _Nonnull, NSString * _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toEventually)(id _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toEventuallyWithDescription)(id _Nonnull, NSString * _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toEventuallyNot)(id _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toEventuallyNotWithDescription)(id _Nonnull, NSString * _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toNotEventually)(id _Nonnull); +@property (nonatomic, readonly, copy) void (^ _Nonnull toNotEventuallyWithDescription)(id _Nonnull, NSString * _Nonnull); ++ (void)failWithMessage:(NSString * _Nonnull)message file:(NSString * _Nonnull)file line:(NSUInteger)line; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + +@class SourceLocation; + +/** + Objective-C interface to the Swift variant of Matcher. +*/ +SWIFT_PROTOCOL("_TtP6Nimble10NMBMatcher_") +@protocol NMBMatcher +- (BOOL)matches:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +- (BOOL)doesNotMatch:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +@end + + +SWIFT_CLASS("_TtC6Nimble23NMBObjCBeCloseToMatcher") +@interface NMBObjCBeCloseToMatcher : NSObject +- (BOOL)matches:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualExpression failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +- (BOOL)doesNotMatch:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualExpression failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +@property (nonatomic, readonly, copy) NMBObjCBeCloseToMatcher * _Nonnull (^ _Nonnull within)(double); +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + + +SWIFT_CLASS("_TtC6Nimble14NMBObjCMatcher") +@interface NMBObjCMatcher : NSObject +- (BOOL)matches:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +- (BOOL)doesNotMatch:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (id _Nonnull)equalMatcher:(NSObject * _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beLessThanMatcher:(id _Nullable)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beGreaterThanMatcher:(id _Nullable)expected; +@end + +@class NMBObjCRaiseExceptionMatcher; + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCRaiseExceptionMatcher * _Nonnull)raiseExceptionMatcher; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)containMatcher:(NSArray * _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)satisfyAnyOfMatcher:(NSArray * _Nonnull)matchers; +@end + +@class NSNumber; + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCBeCloseToMatcher * _Nonnull)beCloseToMatcher:(NSNumber * _Nonnull)expected within:(double)within; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beLessThanOrEqualToMatcher:(id _Nullable)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (id _Nonnull)beAnInstanceOfMatcher:(Class _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)allPassMatcher:(NMBObjCMatcher * _Nonnull)matcher; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (id _Nonnull)beAKindOfMatcher:(Class _Nonnull)expected; +@end + +@class NSString; + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (id _Nonnull)matchMatcher:(NSString * _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)haveCountMatcher:(NSNumber * _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)endWithMatcher:(id _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beNilMatcher; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beEmptyMatcher; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beIdenticalToMatcher:(NSObject * _Nullable)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beginWithMatcher:(id _Nonnull)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beGreaterThanOrEqualToMatcher:(id _Nullable)expected; +@end + + +@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) ++ (NMBObjCMatcher * _Nonnull)beTruthyMatcher; ++ (NMBObjCMatcher * _Nonnull)beFalsyMatcher; ++ (NMBObjCMatcher * _Nonnull)beTrueMatcher; ++ (NMBObjCMatcher * _Nonnull)beFalseMatcher; +@end + +@class NSDictionary; +@class NSException; + +SWIFT_CLASS("_TtC6Nimble28NMBObjCRaiseExceptionMatcher") +@interface NMBObjCRaiseExceptionMatcher : NSObject +- (BOOL)matches:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +- (BOOL)doesNotMatch:(NSObject * _Null_unspecified (^ _Nonnull)(void))actualBlock failureMessage:(FailureMessage * _Nonnull)failureMessage location:(SourceLocation * _Nonnull)location; +@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * _Nonnull (^ _Nonnull named)(NSString * _Nonnull); +@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * _Nonnull (^ _Nonnull reason)(NSString * _Nullable); +@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * _Nonnull (^ _Nonnull userInfo)(NSDictionary * _Nullable); +@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * _Nonnull (^ _Nonnull satisfyingBlock)(void (^ _Nullable)(NSException * _Nonnull)); +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + + +/** + Protocol for types that support beginWith(), endWith(), beEmpty() matchers +*/ +SWIFT_PROTOCOL("_TtP6Nimble20NMBOrderedCollection_") +@protocol NMBOrderedCollection +- (id _Nonnull)objectAtIndex:(NSInteger)index; +@end + + +SWIFT_CLASS("_TtC6Nimble11NMBStringer") +@interface NMBStringer : NSObject ++ (NSString * _Nonnull)stringify:(id _Nullable)obj; +- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; +@end + + +@interface NSArray (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSArray (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSArray (SWIFT_EXTENSION(Nimble)) +@property (nonatomic, readonly, copy) NSString * _Nonnull testDescription; +@end + + +@interface NSDate (SWIFT_EXTENSION(Nimble)) +@property (nonatomic, readonly, copy) NSString * _Nonnull testDescription; +@end + + +@interface NSDate (SWIFT_EXTENSION(Nimble)) +@property (nonatomic, readonly) double doubleValue; +@end + + +@interface NSDictionary (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSHashTable (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSIndexSet (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSIndexSet (SWIFT_EXTENSION(Nimble)) +@property (nonatomic, readonly, copy) NSString * _Nonnull testDescription; +@end + + +@interface NSMapTable (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSNumber (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSNumber (SWIFT_EXTENSION(Nimble)) +- (NSComparisonResult)NMB_compare:(id _Null_unspecified)otherObject; +@end + + +@interface NSNumber (SWIFT_EXTENSION(Nimble)) +@property (nonatomic, readonly, copy) NSString * _Nonnull testDescription; +@end + + +@interface NSSet (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSSet (SWIFT_EXTENSION(Nimble)) +@end + + +@interface NSString (SWIFT_EXTENSION(Nimble)) +- (NSComparisonResult)NMB_compare:(id _Null_unspecified)otherObject; +@end + + +SWIFT_CLASS("_TtC6Nimble14SourceLocation") +@interface SourceLocation : NSObject +@property (nonatomic, readonly, copy) NSString * _Nonnull file; +@property (nonatomic, readonly) NSUInteger line; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@property (nonatomic, readonly, copy) NSString * _Nonnull description; +@end + +#pragma clang diagnostic pop diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Pods-Nimble-umbrella.h b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/Nimble.h similarity index 72% rename from SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Pods-Nimble-umbrella.h rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/Nimble.h index 3b27428..1eab61a 100644 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Pods-Nimble-umbrella.h +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Headers/Nimble.h @@ -1,9 +1,7 @@ -#import - -#import "Nimble.h" -#import "DSL.h" +#import #import "NMBExceptionCapture.h" +#import "NMBStringify.h" +#import "DSL.h" FOUNDATION_EXPORT double NimbleVersionNumber; FOUNDATION_EXPORT const unsigned char NimbleVersionString[]; - diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftdoc b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftdoc new file mode 100644 index 0000000..c0074e8 Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftdoc differ diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftmodule b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftmodule new file mode 100644 index 0000000..1273801 Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftmodule differ diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/module.modulemap b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/module.modulemap similarity index 73% rename from SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/module.modulemap rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/module.modulemap index f433f64..a8769c2 100644 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/module.modulemap +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Modules/module.modulemap @@ -1,5 +1,5 @@ framework module Nimble { - umbrella header "Pods-Nimble-umbrella.h" + umbrella header "Nimble.h" export * module * { export * } diff --git a/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Nimble b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Nimble new file mode 100755 index 0000000..b608a5a Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Nimble differ diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Resources/Info.plist b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Resources/Info.plist similarity index 71% rename from SwiftlineTests/Rome/Nimble.framework/Versions/A/Resources/Info.plist rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Resources/Info.plist index 8d5a9f8..67cece6 100644 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Resources/Info.plist +++ b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/A/Resources/Info.plist @@ -3,13 +3,13 @@ BuildMachineOSBuild - 15B42 + 15G1004 CFBundleDevelopmentRegion en CFBundleExecutable Nimble CFBundleIdentifier - org.cocoapods.Nimble + net.jeffhui.Nimble CFBundleInfoDictionaryVersion 6.0 CFBundleName @@ -17,7 +17,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 3.0.0 + 1.0 CFBundleSignature ???? CFBundleSupportedPlatforms @@ -29,16 +29,23 @@ DTCompiler com.apple.compilers.llvm.clang.1_0 DTPlatformBuild - 7B1005 + 8A218a DTPlatformVersion GM DTSDKBuild - 15A278 + 16A300 DTSDKName - macosx10.11 + macosx10.12 DTXcode - 0711 + 0800 DTXcodeBuild - 7B1005 + 8A218a + NSHumanReadableCopyright + Copyright Β© 2014 Jeff Hui. All rights reserved. + UIDeviceFamily + + 1 + 2 + diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/Current b/SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/Current similarity index 100% rename from SwiftlineTests/Rome/Nimble.framework/Versions/Current rename to SwiftlineTests/Carthage/Build/Mac/Nimble.framework/Versions/Current diff --git a/SwiftlineTests/Carthage/Build/Mac/Quick.framework.dSYM/Contents/Info.plist b/SwiftlineTests/Carthage/Build/Mac/Quick.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..2d39dc1 --- /dev/null +++ b/SwiftlineTests/Carthage/Build/Mac/Quick.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.io.quick.Quick + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/SwiftlineTests/Carthage/Build/Mac/Quick.framework.dSYM/Contents/Resources/DWARF/Quick b/SwiftlineTests/Carthage/Build/Mac/Quick.framework.dSYM/Contents/Resources/DWARF/Quick new file mode 100644 index 0000000..0029159 Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Quick.framework.dSYM/Contents/Resources/DWARF/Quick differ diff --git a/SwiftlineTests/Rome/Quick.framework/Headers b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Headers similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Headers rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Headers diff --git a/SwiftlineTests/Rome/Quick.framework/Modules b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Modules similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Modules rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Modules diff --git a/SwiftlineTests/Rome/Quick.framework/Quick b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Quick similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Quick rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Quick diff --git a/SwiftlineTests/Rome/Quick.framework/Resources b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Resources similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Resources rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Resources diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QCKDSL.h b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QCKDSL.h similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QCKDSL.h rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QCKDSL.h diff --git a/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/Quick-Swift.h b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/Quick-Swift.h new file mode 100644 index 0000000..fa0e0ba --- /dev/null +++ b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/Quick-Swift.h @@ -0,0 +1,351 @@ +// Generated by Apple Swift version 3.0 (swiftlang-800.0.46.2 clang-800.0.38) +#pragma clang diagnostic push + +#if defined(__has_include) && __has_include() +# include +#endif + +#pragma clang diagnostic ignored "-Wauto-import" +#include +#include +#include +#include + +#if !defined(SWIFT_TYPEDEFS) +# define SWIFT_TYPEDEFS 1 +# if defined(__has_include) && __has_include() +# include +# elif !defined(__cplusplus) || __cplusplus < 201103L +typedef uint_least16_t char16_t; +typedef uint_least32_t char32_t; +# endif +typedef float swift_float2 __attribute__((__ext_vector_type__(2))); +typedef float swift_float3 __attribute__((__ext_vector_type__(3))); +typedef float swift_float4 __attribute__((__ext_vector_type__(4))); +typedef double swift_double2 __attribute__((__ext_vector_type__(2))); +typedef double swift_double3 __attribute__((__ext_vector_type__(3))); +typedef double swift_double4 __attribute__((__ext_vector_type__(4))); +typedef int swift_int2 __attribute__((__ext_vector_type__(2))); +typedef int swift_int3 __attribute__((__ext_vector_type__(3))); +typedef int swift_int4 __attribute__((__ext_vector_type__(4))); +typedef unsigned int swift_uint2 __attribute__((__ext_vector_type__(2))); +typedef unsigned int swift_uint3 __attribute__((__ext_vector_type__(3))); +typedef unsigned int swift_uint4 __attribute__((__ext_vector_type__(4))); +#endif + +#if !defined(SWIFT_PASTE) +# define SWIFT_PASTE_HELPER(x, y) x##y +# define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y) +#endif +#if !defined(SWIFT_METATYPE) +# define SWIFT_METATYPE(X) Class +#endif +#if !defined(SWIFT_CLASS_PROPERTY) +# if __has_feature(objc_class_property) +# define SWIFT_CLASS_PROPERTY(...) __VA_ARGS__ +# else +# define SWIFT_CLASS_PROPERTY(...) +# endif +#endif + +#if defined(__has_attribute) && __has_attribute(objc_runtime_name) +# define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X))) +#else +# define SWIFT_RUNTIME_NAME(X) +#endif +#if defined(__has_attribute) && __has_attribute(swift_name) +# define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X))) +#else +# define SWIFT_COMPILE_NAME(X) +#endif +#if defined(__has_attribute) && __has_attribute(objc_method_family) +# define SWIFT_METHOD_FAMILY(X) __attribute__((objc_method_family(X))) +#else +# define SWIFT_METHOD_FAMILY(X) +#endif +#if !defined(SWIFT_CLASS_EXTRA) +# define SWIFT_CLASS_EXTRA +#endif +#if !defined(SWIFT_PROTOCOL_EXTRA) +# define SWIFT_PROTOCOL_EXTRA +#endif +#if !defined(SWIFT_ENUM_EXTRA) +# define SWIFT_ENUM_EXTRA +#endif +#if !defined(SWIFT_CLASS) +# if defined(__has_attribute) && __has_attribute(objc_subclassing_restricted) +# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA +# define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA +# else +# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA +# define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA +# endif +#endif + +#if !defined(SWIFT_PROTOCOL) +# define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA +# define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA +#endif + +#if !defined(SWIFT_EXTENSION) +# define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__) +#endif + +#if !defined(OBJC_DESIGNATED_INITIALIZER) +# if defined(__has_attribute) && __has_attribute(objc_designated_initializer) +# define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer)) +# else +# define OBJC_DESIGNATED_INITIALIZER +# endif +#endif +#if !defined(SWIFT_ENUM) +# define SWIFT_ENUM(_type, _name) enum _name : _type _name; enum SWIFT_ENUM_EXTRA _name : _type +# if defined(__has_feature) && __has_feature(generalized_swift_name) +# define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME) enum _name : _type _name SWIFT_COMPILE_NAME(SWIFT_NAME); enum SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_ENUM_EXTRA _name : _type +# else +# define SWIFT_ENUM_NAMED(_type, _name, SWIFT_NAME) SWIFT_ENUM(_type, _name) +# endif +#endif +#if !defined(SWIFT_UNAVAILABLE) +# define SWIFT_UNAVAILABLE __attribute__((unavailable)) +#endif +#if defined(__has_feature) && __has_feature(modules) +@import Foundation; +@import ObjectiveC; +@import XCTest; +#endif + +#pragma clang diagnostic ignored "-Wproperty-attribute-mismatch" +#pragma clang diagnostic ignored "-Wduplicate-method-arg" + +@interface NSBundle (SWIFT_EXTENSION(Quick)) +@end + + +/** + An object encapsulating the file and line number at which + a particular example is defined. +*/ +SWIFT_CLASS("_TtC5Quick8Callsite") +@interface Callsite : NSObject +/** + The absolute path of the file in which an example is defined. +*/ +@property (nonatomic, readonly, copy) NSString * _Nonnull file; +/** + The line number on which an example is defined. +*/ +@property (nonatomic, readonly) NSUInteger line; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + +@class Example; +@class ExampleMetadata; + +/** + A configuration encapsulates various options you can use + to configure Quick’s behavior. +*/ +SWIFT_CLASS("_TtC5Quick13Configuration") +@interface Configuration : NSObject +/** + Run all examples if none match the configured filters. True by default. +*/ +@property (nonatomic) BOOL runAllWhenEverythingFiltered; +/** + Registers an inclusion filter. + All examples are filtered using all inclusion filters. + The remaining examples are run. If no examples remain, all examples are run. + \param filter A filter that, given an example, returns a value indicating + whether that example should be included in the examples + that are run. + +*/ +- (void)include:(BOOL (^ _Nonnull)(Example * _Nonnull))filter; +/** + Registers an exclusion filter. + All examples that remain after being filtered by the inclusion filters are + then filtered via all exclusion filters. + \param filter A filter that, given an example, returns a value indicating + whether that example should be excluded from the examples + that are run. + +*/ +- (void)exclude:(BOOL (^ _Nonnull)(Example * _Nonnull))filter; +- (void)beforeEachWithMetadata:(void (^ _Nonnull)(ExampleMetadata * _Nonnull))closure; +/** + Like Quick.DSL.beforeEach, this configures Quick to execute the + given closure before each example that is run. The closure + passed to this method is executed before each example Quick runs, + globally across the test suite. You may call this method multiple + times across mulitple +[QuickConfigure configure:] methods in order + to define several closures to run before each example. + Note that, since Quick makes no guarantee as to the order in which + +[QuickConfiguration configure:] methods are evaluated, there is no + guarantee as to the order in which beforeEach closures are evaluated + either. Mulitple beforeEach defined on a single configuration, however, + will be executed in the order they’re defined. + \param closure The closure to be executed before each example + in the test suite. + +*/ +- (void)beforeEach:(void (^ _Nonnull)(void))closure; +- (void)afterEachWithMetadata:(void (^ _Nonnull)(ExampleMetadata * _Nonnull))closure; +/** + Like Quick.DSL.afterEach, this configures Quick to execute the + given closure after each example that is run. The closure + passed to this method is executed after each example Quick runs, + globally across the test suite. You may call this method multiple + times across mulitple +[QuickConfigure configure:] methods in order + to define several closures to run after each example. + Note that, since Quick makes no guarantee as to the order in which + +[QuickConfiguration configure:] methods are evaluated, there is no + guarantee as to the order in which afterEach closures are evaluated + either. Mulitple afterEach defined on a single configuration, however, + will be executed in the order they’re defined. + \param closure The closure to be executed before each example + in the test suite. + +*/ +- (void)afterEach:(void (^ _Nonnull)(void))closure; +/** + Like Quick.DSL.beforeSuite, this configures Quick to execute + the given closure prior to any and all examples that are run. + The two methods are functionally equivalent. +*/ +- (void)beforeSuite:(void (^ _Nonnull)(void))closure; +/** + Like Quick.DSL.afterSuite, this configures Quick to execute + the given closure after all examples have been run. + The two methods are functionally equivalent. +*/ +- (void)afterSuite:(void (^ _Nonnull)(void))closure; +- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; +@end + + +/** + Examples, defined with the \code + it + \endcode function, use assertions to + demonstrate how code should behave. These are like β€œtests” in XCTest. +*/ +SWIFT_CLASS("_TtC5Quick7Example") +@interface Example : NSObject +/** + A boolean indicating whether the example is a shared example; + i.e.: whether it is an example defined with \code + itBehavesLike + \endcode. +*/ +@property (nonatomic) BOOL isSharedExample; +/** + The site at which the example is defined. + This must be set correctly in order for Xcode to highlight + the correct line in red when reporting a failure. +*/ +@property (nonatomic, strong) Callsite * _Nonnull callsite; +@property (nonatomic, readonly, copy) NSString * _Nonnull description; +/** + The example name. A name is a concatenation of the name of + the example group the example belongs to, followed by the + description of the example itself. + The example name is used to generate a test method selector + to be displayed in Xcode’s test navigator. +*/ +@property (nonatomic, readonly, copy) NSString * _Nonnull name; +/** + Executes the example closure, as well as all before and after + closures defined in the its surrounding example groups. +*/ +- (void)run; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + + +/** + Example groups are logical groupings of examples, defined with + the \code + describe + \endcode and \code + context + \endcode functions. Example groups can share + setup and teardown code. +*/ +SWIFT_CLASS("_TtC5Quick12ExampleGroup") +@interface ExampleGroup : NSObject +@property (nonatomic, readonly, copy) NSString * _Nonnull description; +/** + Returns a list of examples that belong to this example group, + or to any of its descendant example groups. +*/ +@property (nonatomic, readonly, copy) NSArray * _Nonnull examples; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + + +/** + A class that encapsulates information about an example, + including the index at which the example was executed, as + well as the example itself. +*/ +SWIFT_CLASS("_TtC5Quick15ExampleMetadata") +@interface ExampleMetadata : NSObject +/** + The example for which this metadata was collected. +*/ +@property (nonatomic, readonly, strong) Example * _Nonnull example; +/** + The index at which this example was executed in the + test suite. +*/ +@property (nonatomic, readonly) NSInteger exampleIndex; +- (nonnull instancetype)init SWIFT_UNAVAILABLE; +@end + + +/** + A namespace for filter flag keys, defined primarily to make the + keys available in Objective-C. +*/ +SWIFT_CLASS("_TtC5Quick6Filter") +@interface Filter : NSObject +/** + Example and example groups with [Focused: true] are included in test runs, + excluding all other examples without this flag. Use this to only run one or + two tests that you’re currently focusing on. +*/ +SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, copy) NSString * _Nonnull focused;) ++ (NSString * _Nonnull)focused; +/** + Example and example groups with [Pending: true] are excluded from test runs. + Use this to temporarily suspend examples that you know do not pass yet. +*/ +SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, copy) NSString * _Nonnull pending;) ++ (NSString * _Nonnull)pending; +- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; +@end + + +/** + A base class for a class cluster of Quick test suites, that should correctly + build dynamic test suites for XCTest to execute. +*/ +SWIFT_CLASS("_TtC5Quick14QuickTestSuite") +@interface QuickTestSuite : XCTestSuite +/** + Construct a test suite for a specific, selected subset of test cases (rather + than the default, which as all test cases). + If this method is called multiple times for the same test case class, e.g.. + FooSpec/testFoo + FooSpec/testBar + It is expected that the first call should return a valid test suite, and + all subsequent calls should return \code + nil + \endcode. +*/ ++ (QuickTestSuite * _Nullable)selectedTestSuiteForTestCaseWithName:(NSString * _Nonnull)name; +- (nonnull instancetype)initWithName:(NSString * _Nonnull)name OBJC_DESIGNATED_INITIALIZER; +@end + +#pragma clang diagnostic pop diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Quick.h b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/Quick.h similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Quick.h rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/Quick.h diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QuickConfiguration.h b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QuickConfiguration.h similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QuickConfiguration.h rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QuickConfiguration.h diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QuickSpec.h b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QuickSpec.h similarity index 93% rename from SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QuickSpec.h rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QuickSpec.h index 08d0079..105a97e 100644 --- a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/QuickSpec.h +++ b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Headers/QuickSpec.h @@ -33,13 +33,15 @@ Override this method in your spec to define a set of example groups and examples. - override class func spec() { - describe("winter") { - it("is coming") { - // ... - } + @code + override func spec() { + describe("winter") { + it("is coming") { + // ... } } + } + @endcode See DSL.swift for more information on what syntax is available. */ diff --git a/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftdoc b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftdoc new file mode 100644 index 0000000..935cbbf Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftdoc differ diff --git a/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftmodule b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftmodule new file mode 100644 index 0000000..4c91028 Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftmodule differ diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/module.modulemap b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/module.modulemap similarity index 73% rename from SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/module.modulemap rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/module.modulemap index 7bd31a1..43f1882 100644 --- a/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/module.modulemap +++ b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Modules/module.modulemap @@ -1,5 +1,5 @@ framework module Quick { - umbrella header "Pods-Quick-umbrella.h" + umbrella header "Quick.h" export * module * { export * } diff --git a/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Quick b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Quick new file mode 100755 index 0000000..9264f19 Binary files /dev/null and b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Quick differ diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Resources/Info.plist b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Resources/Info.plist similarity index 75% rename from SwiftlineTests/Rome/Quick.framework/Versions/A/Resources/Info.plist rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Resources/Info.plist index faa3d6d..5dc6a9e 100644 --- a/SwiftlineTests/Rome/Quick.framework/Versions/A/Resources/Info.plist +++ b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/A/Resources/Info.plist @@ -3,13 +3,13 @@ BuildMachineOSBuild - 15B42 + 15G1004 CFBundleDevelopmentRegion en CFBundleExecutable Quick CFBundleIdentifier - org.cocoapods.Quick + io.quick.Quick CFBundleInfoDictionaryVersion 6.0 CFBundleName @@ -17,7 +17,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 0.8.0 + 1.0 CFBundleSignature ???? CFBundleSupportedPlatforms @@ -29,16 +29,18 @@ DTCompiler com.apple.compilers.llvm.clang.1_0 DTPlatformBuild - 7B1005 + 8A218a DTPlatformVersion GM DTSDKBuild - 15A278 + 16A300 DTSDKName - macosx10.11 + macosx10.12 DTXcode - 0711 + 0800 DTXcodeBuild - 7B1005 + 8A218a + NSHumanReadableCopyright + Copyright Β© 2014 - present, Quick Team. All rights reserved. diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/Current b/SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/Current similarity index 100% rename from SwiftlineTests/Rome/Quick.framework/Versions/Current rename to SwiftlineTests/Carthage/Build/Mac/Quick.framework/Versions/Current diff --git a/SwiftlineTests/Podfile.lock b/SwiftlineTests/Podfile.lock deleted file mode 100644 index 3f15e30..0000000 --- a/SwiftlineTests/Podfile.lock +++ /dev/null @@ -1,13 +0,0 @@ -PODS: - - Nimble (3.0.0) - - Quick (0.8.0) - -DEPENDENCIES: - - Nimble (~> 3.0.0) - - Quick (~> 0.8.0) - -SPEC CHECKSUMS: - Nimble: 4c353d43735b38b545cbb4cb91504588eb5de926 - Quick: 563d0f6ec5f72e394645adb377708639b7dd38ab - -COCOAPODS: 0.39.0 diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/NMBExceptionCapture.h b/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/NMBExceptionCapture.h deleted file mode 100644 index 8be4a5a..0000000 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/NMBExceptionCapture.h +++ /dev/null @@ -1,8 +0,0 @@ -#import - -@interface NMBExceptionCapture : NSObject - -- (id)initWithHandler:(void(^)(NSException *))handler finally:(void(^)())finally; -- (void)tryBlock:(void(^)())unsafeBlock; - -@end diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Nimble-Swift.h b/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Nimble-Swift.h deleted file mode 100644 index 6c868b3..0000000 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Nimble-Swift.h +++ /dev/null @@ -1,378 +0,0 @@ -// Generated by Apple Swift version 2.1 (swiftlang-700.1.101.6 clang-700.1.76) -#pragma clang diagnostic push - -#if defined(__has_include) && __has_include() -# include -#endif - -#pragma clang diagnostic ignored "-Wauto-import" -#include -#include -#include -#include - -#if defined(__has_include) && __has_include() -# include -#elif !defined(__cplusplus) || __cplusplus < 201103L -typedef uint_least16_t char16_t; -typedef uint_least32_t char32_t; -#endif - -typedef struct _NSZone NSZone; - -#if !defined(SWIFT_PASTE) -# define SWIFT_PASTE_HELPER(x, y) x##y -# define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y) -#endif -#if !defined(SWIFT_METATYPE) -# define SWIFT_METATYPE(X) Class -#endif - -#if defined(__has_attribute) && __has_attribute(objc_runtime_name) -# define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X))) -#else -# define SWIFT_RUNTIME_NAME(X) -#endif -#if defined(__has_attribute) && __has_attribute(swift_name) -# define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X))) -#else -# define SWIFT_COMPILE_NAME(X) -#endif -#if !defined(SWIFT_CLASS_EXTRA) -# define SWIFT_CLASS_EXTRA -#endif -#if !defined(SWIFT_PROTOCOL_EXTRA) -# define SWIFT_PROTOCOL_EXTRA -#endif -#if !defined(SWIFT_ENUM_EXTRA) -# define SWIFT_ENUM_EXTRA -#endif -#if !defined(SWIFT_CLASS) -# if defined(__has_attribute) && __has_attribute(objc_subclassing_restricted) -# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA -# define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA -# else -# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA -# define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA -# endif -#endif - -#if !defined(SWIFT_PROTOCOL) -# define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA -# define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA -#endif - -#if !defined(SWIFT_EXTENSION) -# define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__) -#endif - -#if !defined(OBJC_DESIGNATED_INITIALIZER) -# if defined(__has_attribute) && __has_attribute(objc_designated_initializer) -# define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer)) -# else -# define OBJC_DESIGNATED_INITIALIZER -# endif -#endif -#if !defined(SWIFT_ENUM) -# define SWIFT_ENUM(_type, _name) enum _name : _type _name; enum SWIFT_ENUM_EXTRA _name : _type -#endif -typedef float swift_float2 __attribute__((__ext_vector_type__(2))); -typedef float swift_float3 __attribute__((__ext_vector_type__(3))); -typedef float swift_float4 __attribute__((__ext_vector_type__(4))); -typedef double swift_double2 __attribute__((__ext_vector_type__(2))); -typedef double swift_double3 __attribute__((__ext_vector_type__(3))); -typedef double swift_double4 __attribute__((__ext_vector_type__(4))); -typedef int swift_int2 __attribute__((__ext_vector_type__(2))); -typedef int swift_int3 __attribute__((__ext_vector_type__(3))); -typedef int swift_int4 __attribute__((__ext_vector_type__(4))); -#if defined(__has_feature) && __has_feature(modules) -@import ObjectiveC; -@import Foundation; -#endif - -#pragma clang diagnostic ignored "-Wproperty-attribute-mismatch" -#pragma clang diagnostic ignored "-Wduplicate-method-arg" - - -/// Encapsulates the failure message that matchers can report to the end user. -/// -/// This is shared state between Nimble and matchers that mutate this value. -SWIFT_CLASS("_TtC6Nimble14FailureMessage") -@interface FailureMessage : NSObject -@property (nonatomic, copy) NSString * __nonnull expected; -@property (nonatomic, copy) NSString * __nullable actualValue; -@property (nonatomic, copy) NSString * __nonnull to; -@property (nonatomic, copy) NSString * __nonnull postfixMessage; -@property (nonatomic, copy) NSString * __nonnull postfixActual; -@property (nonatomic, copy) NSString * __nullable userDescription; -@property (nonatomic, copy) NSString * __nonnull stringValue; -- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; -- (nonnull instancetype)initWithStringValue:(NSString * __nonnull)stringValue OBJC_DESIGNATED_INITIALIZER; -@end - - - -/// Protocol for types that support only beEmpty(), haveCount() matchers -SWIFT_PROTOCOL("_TtP6Nimble13NMBCollection_") -@protocol NMBCollection -@property (nonatomic, readonly) NSInteger count; -@end - - - -/// Protocol for types to support beLessThan(), beLessThanOrEqualTo(), beGreaterThan(), beGreaterThanOrEqualTo(), and equal() matchers. -/// -/// Types that conform to Swift's Comparable protocol will work implicitly too -SWIFT_PROTOCOL("_TtP6Nimble13NMBComparable_") -@protocol NMBComparable -- (NSComparisonResult)NMB_compare:(id __null_unspecified)otherObject; -@end - - - -/// Protocol for types that support contain() matcher. -SWIFT_PROTOCOL("_TtP6Nimble12NMBContainer_") -@protocol NMBContainer -- (BOOL)containsObject:(id __null_unspecified)object; -@end - - - -/// Protocol for types to support beCloseTo() matcher -SWIFT_PROTOCOL("_TtP6Nimble20NMBDoubleConvertible_") -@protocol NMBDoubleConvertible -@property (nonatomic, readonly) double doubleValue; -@end - -@protocol NMBMatcher; - -SWIFT_CLASS("_TtC6Nimble14NMBExpectation") -@interface NMBExpectation : NSObject -- (nonnull instancetype)initWithActualBlock:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock negative:(BOOL)negative file:(NSString * __nonnull)file line:(NSUInteger)line OBJC_DESIGNATED_INITIALIZER; -@property (nonatomic, readonly, copy) NMBExpectation * __nonnull (^ __nonnull withTimeout)(NSTimeInterval); -@property (nonatomic, readonly, copy) void (^ __nonnull to)(id __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toWithDescription)(id __nonnull, NSString * __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toNot)(id __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toNotWithDescription)(id __nonnull, NSString * __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull notTo)(id __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull notToWithDescription)(id __nonnull, NSString * __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toEventually)(id __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toEventuallyWithDescription)(id __nonnull, NSString * __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toEventuallyNot)(id __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toEventuallyNotWithDescription)(id __nonnull, NSString * __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toNotEventually)(id __nonnull); -@property (nonatomic, readonly, copy) void (^ __nonnull toNotEventuallyWithDescription)(id __nonnull, NSString * __nonnull); -+ (void)failWithMessage:(NSString * __nonnull)message file:(NSString * __nonnull)file line:(NSUInteger)line; -@end - -@class SourceLocation; - - -/// Objective-C interface to the Swift variant of Matcher. -SWIFT_PROTOCOL("_TtP6Nimble10NMBMatcher_") -@protocol NMBMatcher -- (BOOL)matches:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -- (BOOL)doesNotMatch:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -@end - - -SWIFT_CLASS("_TtC6Nimble23NMBObjCBeCloseToMatcher") -@interface NMBObjCBeCloseToMatcher : NSObject -- (BOOL)matches:(NSObject * __null_unspecified (^ __nonnull)(void))actualExpression failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -- (BOOL)doesNotMatch:(NSObject * __null_unspecified (^ __nonnull)(void))actualExpression failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -@property (nonatomic, readonly, copy) NMBObjCBeCloseToMatcher * __nonnull (^ __nonnull within)(double); -@end - - -SWIFT_CLASS("_TtC6Nimble14NMBObjCMatcher") -@interface NMBObjCMatcher : NSObject -- (BOOL)matches:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -- (BOOL)doesNotMatch:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -@end - -@class NMBObjCRaiseExceptionMatcher; - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCRaiseExceptionMatcher * __nonnull)raiseExceptionMatcher; -@end - -@class NSString; - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (id __nonnull)matchMatcher:(NSString * __nonnull)expected; -@end - -@class NSNumber; - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)haveCountMatcher:(NSNumber * __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (id __nonnull)equalMatcher:(NSObject * __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)endWithMatcher:(id __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)containMatcher:(NSArray * __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beNilMatcher; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beLessThanOrEqualToMatcher:(id __nullable)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)allPassMatcher:(NMBObjCMatcher * __nonnull)matcher; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beIdenticalToMatcher:(NSObject * __nullable)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beGreaterThanOrEqualToMatcher:(id __nullable)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beGreaterThanMatcher:(id __nullable)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beginWithMatcher:(id __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beEmptyMatcher; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCBeCloseToMatcher * __nonnull)beCloseToMatcher:(NSNumber * __nonnull)expected within:(double)within; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (id __nonnull)beAnInstanceOfMatcher:(Class __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (id __nonnull)beAKindOfMatcher:(Class __nonnull)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beLessThanMatcher:(id __nullable)expected; -@end - - -@interface NMBObjCMatcher (SWIFT_EXTENSION(Nimble)) -+ (NMBObjCMatcher * __nonnull)beTruthyMatcher; -+ (NMBObjCMatcher * __nonnull)beFalsyMatcher; -+ (NMBObjCMatcher * __nonnull)beTrueMatcher; -+ (NMBObjCMatcher * __nonnull)beFalseMatcher; -@end - -@class NSDictionary; -@class NSException; - -SWIFT_CLASS("_TtC6Nimble28NMBObjCRaiseExceptionMatcher") -@interface NMBObjCRaiseExceptionMatcher : NSObject -- (BOOL)matches:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -- (BOOL)doesNotMatch:(NSObject * __null_unspecified (^ __nonnull)(void))actualBlock failureMessage:(FailureMessage * __nonnull)failureMessage location:(SourceLocation * __nonnull)location; -@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * __nonnull (^ __nonnull named)(NSString * __nonnull); -@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * __nonnull (^ __nonnull reason)(NSString * __nullable); -@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * __nonnull (^ __nonnull userInfo)(NSDictionary * __nullable); -@property (nonatomic, readonly, copy) NMBObjCRaiseExceptionMatcher * __nonnull (^ __nonnull satisfyingBlock)(void (^ __nullable)(NSException * __nonnull)); -@end - - - -/// Protocol for types that support beginWith(), endWith(), beEmpty() matchers -SWIFT_PROTOCOL("_TtP6Nimble20NMBOrderedCollection_") -@protocol NMBOrderedCollection -- (NSInteger)indexOfObject:(id __null_unspecified)object; -@end - - -@interface NSArray (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSArray (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSArray (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSDate (SWIFT_EXTENSION(Nimble)) -@property (nonatomic, readonly) double doubleValue; -@end - - -@interface NSDictionary (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSHashTable (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSHashTable (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSMapTable (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSNumber (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSNumber (SWIFT_EXTENSION(Nimble)) -- (NSComparisonResult)NMB_compare:(id __null_unspecified)otherObject; -@end - - -@interface NSSet (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSSet (SWIFT_EXTENSION(Nimble)) -@end - - -@interface NSString (SWIFT_EXTENSION(Nimble)) -- (NSComparisonResult)NMB_compare:(id __null_unspecified)otherObject; -@end - - -SWIFT_CLASS("_TtC6Nimble14SourceLocation") -@interface SourceLocation : NSObject -@property (nonatomic, readonly, copy) NSString * __nonnull file; -@property (nonatomic, readonly) NSUInteger line; -@property (nonatomic, readonly, copy) NSString * __nonnull description; -@end - -#pragma clang diagnostic pop diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Nimble.h b/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Nimble.h deleted file mode 100644 index 296760c..0000000 --- a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Headers/Nimble.h +++ /dev/null @@ -1,6 +0,0 @@ -#import -#import "NMBExceptionCapture.h" -#import "DSL.h" - -FOUNDATION_EXPORT double NimbleVersionNumber; -FOUNDATION_EXPORT const unsigned char NimbleVersionString[]; \ No newline at end of file diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftdoc b/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftdoc deleted file mode 100644 index 9b91418..0000000 Binary files a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftdoc and /dev/null differ diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftmodule b/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftmodule deleted file mode 100644 index 23b07c3..0000000 Binary files a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Modules/Nimble.swiftmodule/x86_64.swiftmodule and /dev/null differ diff --git a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Nimble b/SwiftlineTests/Rome/Nimble.framework/Versions/A/Nimble deleted file mode 100755 index b387f05..0000000 Binary files a/SwiftlineTests/Rome/Nimble.framework/Versions/A/Nimble and /dev/null differ diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Pods-Quick-umbrella.h b/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Pods-Quick-umbrella.h deleted file mode 100644 index b23d289..0000000 --- a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Pods-Quick-umbrella.h +++ /dev/null @@ -1,10 +0,0 @@ -#import - -#import "QuickConfiguration.h" -#import "QCKDSL.h" -#import "Quick.h" -#import "QuickSpec.h" - -FOUNDATION_EXPORT double QuickVersionNumber; -FOUNDATION_EXPORT const unsigned char QuickVersionString[]; - diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Quick-Swift.h b/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Quick-Swift.h deleted file mode 100644 index e090212..0000000 --- a/SwiftlineTests/Rome/Quick.framework/Versions/A/Headers/Quick-Swift.h +++ /dev/null @@ -1,237 +0,0 @@ -// Generated by Apple Swift version 2.1 (swiftlang-700.1.101.6 clang-700.1.76) -#pragma clang diagnostic push - -#if defined(__has_include) && __has_include() -# include -#endif - -#pragma clang diagnostic ignored "-Wauto-import" -#include -#include -#include -#include - -#if defined(__has_include) && __has_include() -# include -#elif !defined(__cplusplus) || __cplusplus < 201103L -typedef uint_least16_t char16_t; -typedef uint_least32_t char32_t; -#endif - -typedef struct _NSZone NSZone; - -#if !defined(SWIFT_PASTE) -# define SWIFT_PASTE_HELPER(x, y) x##y -# define SWIFT_PASTE(x, y) SWIFT_PASTE_HELPER(x, y) -#endif -#if !defined(SWIFT_METATYPE) -# define SWIFT_METATYPE(X) Class -#endif - -#if defined(__has_attribute) && __has_attribute(objc_runtime_name) -# define SWIFT_RUNTIME_NAME(X) __attribute__((objc_runtime_name(X))) -#else -# define SWIFT_RUNTIME_NAME(X) -#endif -#if defined(__has_attribute) && __has_attribute(swift_name) -# define SWIFT_COMPILE_NAME(X) __attribute__((swift_name(X))) -#else -# define SWIFT_COMPILE_NAME(X) -#endif -#if !defined(SWIFT_CLASS_EXTRA) -# define SWIFT_CLASS_EXTRA -#endif -#if !defined(SWIFT_PROTOCOL_EXTRA) -# define SWIFT_PROTOCOL_EXTRA -#endif -#if !defined(SWIFT_ENUM_EXTRA) -# define SWIFT_ENUM_EXTRA -#endif -#if !defined(SWIFT_CLASS) -# if defined(__has_attribute) && __has_attribute(objc_subclassing_restricted) -# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_CLASS_EXTRA -# define SWIFT_CLASS_NAMED(SWIFT_NAME) __attribute__((objc_subclassing_restricted)) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA -# else -# define SWIFT_CLASS(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA -# define SWIFT_CLASS_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_CLASS_EXTRA -# endif -#endif - -#if !defined(SWIFT_PROTOCOL) -# define SWIFT_PROTOCOL(SWIFT_NAME) SWIFT_RUNTIME_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA -# define SWIFT_PROTOCOL_NAMED(SWIFT_NAME) SWIFT_COMPILE_NAME(SWIFT_NAME) SWIFT_PROTOCOL_EXTRA -#endif - -#if !defined(SWIFT_EXTENSION) -# define SWIFT_EXTENSION(M) SWIFT_PASTE(M##_Swift_, __LINE__) -#endif - -#if !defined(OBJC_DESIGNATED_INITIALIZER) -# if defined(__has_attribute) && __has_attribute(objc_designated_initializer) -# define OBJC_DESIGNATED_INITIALIZER __attribute__((objc_designated_initializer)) -# else -# define OBJC_DESIGNATED_INITIALIZER -# endif -#endif -#if !defined(SWIFT_ENUM) -# define SWIFT_ENUM(_type, _name) enum _name : _type _name; enum SWIFT_ENUM_EXTRA _name : _type -#endif -typedef float swift_float2 __attribute__((__ext_vector_type__(2))); -typedef float swift_float3 __attribute__((__ext_vector_type__(3))); -typedef float swift_float4 __attribute__((__ext_vector_type__(4))); -typedef double swift_double2 __attribute__((__ext_vector_type__(2))); -typedef double swift_double3 __attribute__((__ext_vector_type__(3))); -typedef double swift_double4 __attribute__((__ext_vector_type__(4))); -typedef int swift_int2 __attribute__((__ext_vector_type__(2))); -typedef int swift_int3 __attribute__((__ext_vector_type__(3))); -typedef int swift_int4 __attribute__((__ext_vector_type__(4))); -#if defined(__has_feature) && __has_feature(modules) -@import ObjectiveC; -#endif - -#pragma clang diagnostic ignored "-Wproperty-attribute-mismatch" -#pragma clang diagnostic ignored "-Wduplicate-method-arg" - - -/// An object encapsulating the file and line number at which a particular example is defined. -SWIFT_CLASS("_TtC5Quick8Callsite") -@interface Callsite : NSObject - -/// The absolute path of the file in which an example is defined. -@property (nonatomic, readonly, copy) NSString * __nonnull file; - -/// The line number on which an example is defined. -@property (nonatomic, readonly) NSUInteger line; -@end - -@class Example; -@class ExampleMetadata; - - -/// A configuration encapsulates various options you can use to configure Quick's behavior. -SWIFT_CLASS("_TtC5Quick13Configuration") -@interface Configuration : NSObject - -/// Run all examples if none match the configured filters. True by default. -@property (nonatomic) BOOL runAllWhenEverythingFiltered; - -/// Registers an inclusion filter. -/// -/// All examples are filtered using all inclusion filters. -/// The remaining examples are run. If no examples remain, all examples are run. -/// -/// \param filter A filter that, given an example, returns a value indicating -/// whether that example should be included in the examples -/// that are run. -- (void)include:(BOOL (^ __nonnull)(Example * __nonnull))filter; - -/// Registers an exclusion filter. -/// -/// All examples that remain after being filtered by the inclusion filters are -/// then filtered via all exclusion filters. -/// -/// \param filter A filter that, given an example, returns a value indicating -/// whether that example should be excluded from the examples -/// that are run. -- (void)exclude:(BOOL (^ __nonnull)(Example * __nonnull))filter; - -/// Identical to Quick.Configuration.beforeEach, except the closure is provided with metadata on the example that the closure is being run prior to. -- (void)beforeEachWithMetadata:(void (^ __nonnull)(ExampleMetadata * __nonnull))closure; - -/// Like Quick.DSL.beforeEach, this configures Quick to execute the given closure before each example that is run. The closure passed to this method is executed before each example Quick runs, globally across the test suite. You may call this method multiple times across mulitple +[QuickConfigure configure:] methods in order to define several closures to run before each example. -/// -/// Note that, since Quick makes no guarantee as to the order in which -/// +[QuickConfiguration configure:] methods are evaluated, there is no -/// guarantee as to the order in which beforeEach closures are evaluated -/// either. Mulitple beforeEach defined on a single configuration, however, -/// will be executed in the order they're defined. -/// -/// \param closure The closure to be executed before each example -/// in the test suite. -- (void)beforeEach:(void (^ __nonnull)(void))closure; - -/// Identical to Quick.Configuration.afterEach, except the closure is provided with metadata on the example that the closure is being run after. -- (void)afterEachWithMetadata:(void (^ __nonnull)(ExampleMetadata * __nonnull))closure; - -/// Like Quick.DSL.afterEach, this configures Quick to execute the given closure after each example that is run. The closure passed to this method is executed after each example Quick runs, globally across the test suite. You may call this method multiple times across mulitple +[QuickConfigure configure:] methods in order to define several closures to run after each example. -/// -/// Note that, since Quick makes no guarantee as to the order in which -/// +[QuickConfiguration configure:] methods are evaluated, there is no -/// guarantee as to the order in which afterEach closures are evaluated -/// either. Mulitple afterEach defined on a single configuration, however, -/// will be executed in the order they're defined. -/// -/// \param closure The closure to be executed before each example -/// in the test suite. -- (void)afterEach:(void (^ __nonnull)(void))closure; - -/// Like Quick.DSL.beforeSuite, this configures Quick to execute the given closure prior to any and all examples that are run. The two methods are functionally equivalent. -- (void)beforeSuite:(void (^ __nonnull)(void))closure; - -/// Like Quick.DSL.afterSuite, this configures Quick to execute the given closure after all examples have been run. The two methods are functionally equivalent. -- (void)afterSuite:(void (^ __nonnull)(void))closure; -- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; -@end - - - -/// Examples, defined with the it function, use assertions to demonstrate how code should behave. These are like "tests" in XCTest. -SWIFT_CLASS("_TtC5Quick7Example") -@interface Example : NSObject - -/// A boolean indicating whether the example is a shared example; i.e.: whether it is an example defined with itBehavesLike. -@property (nonatomic) BOOL isSharedExample; - -/// The site at which the example is defined. This must be set correctly in order for Xcode to highlight the correct line in red when reporting a failure. -@property (nonatomic, strong) Callsite * __nonnull callsite; -@property (nonatomic, readonly, copy) NSString * __nonnull description; - -/// The example name. A name is a concatenation of the name of the example group the example belongs to, followed by the description of the example itself. -/// -/// The example name is used to generate a test method selector -/// to be displayed in Xcode's test navigator. -@property (nonatomic, readonly, copy) NSString * __nonnull name; - -/// Executes the example closure, as well as all before and after closures defined in the its surrounding example groups. -- (void)run; -@end - - - -/// Example groups are logical groupings of examples, defined with the describe and context functions. Example groups can share setup and teardown code. -SWIFT_CLASS("_TtC5Quick12ExampleGroup") -@interface ExampleGroup : NSObject -@property (nonatomic, readonly, copy) NSString * __nonnull description; - -/// Returns a list of examples that belong to this example group, or to any of its descendant example groups. -@property (nonatomic, readonly, copy) NSArray * __nonnull examples; -@end - - - -/// A class that encapsulates information about an example, including the index at which the example was executed, as well as the example itself. -SWIFT_CLASS("_TtC5Quick15ExampleMetadata") -@interface ExampleMetadata : NSObject - -/// The example for which this metadata was collected. -@property (nonatomic, readonly, strong) Example * __nonnull example; - -/// The index at which this example was executed in the test suite. -@property (nonatomic, readonly) NSInteger exampleIndex; -@end - - - -/// A namespace for filter flag keys, defined primarily to make the keys available in Objective-C. -SWIFT_CLASS("_TtC5Quick6Filter") -@interface Filter : NSObject - -/// Example and example groups with [Focused: true] are included in test runs, excluding all other examples without this flag. Use this to only run one or two tests that you're currently focusing on. -+ (NSString * __nonnull)focused; - -/// Example and example groups with [Pending: true] are excluded from test runs. Use this to temporarily suspend examples that you know do not pass yet. -+ (NSString * __nonnull)pending; -- (nonnull instancetype)init OBJC_DESIGNATED_INITIALIZER; -@end - -#pragma clang diagnostic pop diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftdoc b/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftdoc deleted file mode 100644 index de768a7..0000000 Binary files a/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftdoc and /dev/null differ diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftmodule b/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftmodule deleted file mode 100644 index 31ec3c1..0000000 Binary files a/SwiftlineTests/Rome/Quick.framework/Versions/A/Modules/Quick.swiftmodule/x86_64.swiftmodule and /dev/null differ diff --git a/SwiftlineTests/Rome/Quick.framework/Versions/A/Quick b/SwiftlineTests/Rome/Quick.framework/Versions/A/Quick deleted file mode 100755 index 4d9fd81..0000000 Binary files a/SwiftlineTests/Rome/Quick.framework/Versions/A/Quick and /dev/null differ diff --git a/SwiftlineTests/Swiftline.xcodeproj/project.pbxproj b/SwiftlineTests/Swiftline.xcodeproj/project.pbxproj index 43b6436..24497a8 100644 --- a/SwiftlineTests/Swiftline.xcodeproj/project.pbxproj +++ b/SwiftlineTests/Swiftline.xcodeproj/project.pbxproj @@ -17,12 +17,12 @@ D727665D1BF416F700126D99 /* AskTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D72766551BF416F700126D99 /* AskTests.swift */; }; D727665E1BF416F700126D99 /* AskSettingsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D72766561BF416F700126D99 /* AskSettingsTests.swift */; }; D727665F1BF416F700126D99 /* AgreeTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D72766571BF416F700126D99 /* AgreeTests.swift */; }; - D72766621BF4178900126D99 /* Nimble.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D72766601BF4178900126D99 /* Nimble.framework */; }; - D72766631BF4178900126D99 /* Quick.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D72766611BF4178900126D99 /* Quick.framework */; }; - D72766651BF417AF00126D99 /* Nimble.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = D72766601BF4178900126D99 /* Nimble.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; - D72766661BF417AF00126D99 /* Quick.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = D72766611BF4178900126D99 /* Quick.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; D72E3EBD1C052E2E00B77D49 /* ENVTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D72E3EBC1C052E2E00B77D49 /* ENVTests.swift */; }; D72E3EC51C05B4FE00B77D49 /* ArgsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D72E3EC41C05B4FE00B77D49 /* ArgsTests.swift */; }; + D77488291D9AE0F2001EC08E /* Nimble.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D77488271D9AE0F2001EC08E /* Nimble.framework */; }; + D774882A1D9AE0F2001EC08E /* Quick.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D77488281D9AE0F2001EC08E /* Quick.framework */; }; + D774882B1D9AE10B001EC08E /* Nimble.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = D77488271D9AE0F2001EC08E /* Nimble.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + D774882C1D9AE10B001EC08E /* Quick.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = D77488281D9AE0F2001EC08E /* Quick.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; D7C7F8BB1C71289A00EA5D29 /* Agree.swift in Sources */ = {isa = PBXBuildFile; fileRef = D7C7F89F1C71289A00EA5D29 /* Agree.swift */; }; D7C7F8BC1C71289A00EA5D29 /* AgreeSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = D7C7F8A01C71289A00EA5D29 /* AgreeSettings.swift */; }; D7C7F8BD1C71289A00EA5D29 /* ArgConvertible.swift in Sources */ = {isa = PBXBuildFile; fileRef = D7C7F8A11C71289A00EA5D29 /* ArgConvertible.swift */; }; @@ -71,8 +71,8 @@ dstPath = ""; dstSubfolderSpec = 10; files = ( - D72766651BF417AF00126D99 /* Nimble.framework in CopyFiles */, - D72766661BF417AF00126D99 /* Quick.framework in CopyFiles */, + D774882B1D9AE10B001EC08E /* Nimble.framework in CopyFiles */, + D774882C1D9AE10B001EC08E /* Quick.framework in CopyFiles */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -92,10 +92,10 @@ D72766551BF416F700126D99 /* AskTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AskTests.swift; sourceTree = ""; }; D72766561BF416F700126D99 /* AskSettingsTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AskSettingsTests.swift; sourceTree = ""; }; D72766571BF416F700126D99 /* AgreeTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AgreeTests.swift; sourceTree = ""; }; - D72766601BF4178900126D99 /* Nimble.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Nimble.framework; path = Rome/Nimble.framework; sourceTree = SOURCE_ROOT; }; - D72766611BF4178900126D99 /* Quick.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Quick.framework; path = Rome/Quick.framework; sourceTree = SOURCE_ROOT; }; D72E3EBC1C052E2E00B77D49 /* ENVTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ENVTests.swift; sourceTree = ""; }; D72E3EC41C05B4FE00B77D49 /* ArgsTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ArgsTests.swift; sourceTree = ""; }; + D77488271D9AE0F2001EC08E /* Nimble.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Nimble.framework; path = Carthage/Build/Mac/Nimble.framework; sourceTree = SOURCE_ROOT; }; + D77488281D9AE0F2001EC08E /* Quick.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Quick.framework; path = Carthage/Build/Mac/Quick.framework; sourceTree = SOURCE_ROOT; }; D7C7F89F1C71289A00EA5D29 /* Agree.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Agree.swift; path = ../../Source/Agree.swift; sourceTree = ""; }; D7C7F8A01C71289A00EA5D29 /* AgreeSettings.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = AgreeSettings.swift; path = ../../Source/AgreeSettings.swift; sourceTree = ""; }; D7C7F8A11C71289A00EA5D29 /* ArgConvertible.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = ArgConvertible.swift; path = ../../Source/ArgConvertible.swift; sourceTree = ""; }; @@ -140,8 +140,8 @@ buildActionMask = 2147483647; files = ( D727660E1BF416AC00126D99 /* Swiftline.framework in Frameworks */, - D72766621BF4178900126D99 /* Nimble.framework in Frameworks */, - D72766631BF4178900126D99 /* Quick.framework in Frameworks */, + D77488291D9AE0F2001EC08E /* Nimble.framework in Frameworks */, + D774882A1D9AE0F2001EC08E /* Quick.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -206,8 +206,8 @@ D72766111BF416AC00126D99 /* SwiftlineTests */ = { isa = PBXGroup; children = ( - D72766601BF4178900126D99 /* Nimble.framework */, - D72766611BF4178900126D99 /* Quick.framework */, + D77488271D9AE0F2001EC08E /* Nimble.framework */, + D77488281D9AE0F2001EC08E /* Quick.framework */, D72766501BF416F700126D99 /* AgreeSettingsTest.swift */, D72766511BF416F700126D99 /* ColorizerTest.swift */, D72766521BF416F700126D99 /* RunnerTests.swift */, @@ -290,6 +290,7 @@ }; D727660C1BF416AC00126D99 = { CreatedOnToolsVersion = 7.1.1; + LastSwiftMigration = 0800; }; }; }; @@ -498,6 +499,7 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 3.0; }; name = Debug; }; @@ -519,6 +521,7 @@ PRODUCT_BUNDLE_IDENTIFIER = nsomar.Swiftline; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; + SWIFT_VERSION = 3.0; }; name = Release; }; @@ -530,12 +533,14 @@ FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/Rome", + "$(PROJECT_DIR)/Carthage/Build/Mac", ); INFOPLIST_FILE = SwiftlineTests/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = nsomar.SwiftlineTests; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 3.0; }; name = Debug; }; @@ -547,11 +552,13 @@ FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)/Rome", + "$(PROJECT_DIR)/Carthage/Build/Mac", ); INFOPLIST_FILE = SwiftlineTests/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = nsomar.SwiftlineTests; PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 3.0; }; name = Release; }; diff --git a/SwiftlineTests/SwiftlineTests/ArgsTests.swift b/SwiftlineTests/SwiftlineTests/ArgsTests.swift index 225b708..49fa54b 100644 --- a/SwiftlineTests/SwiftlineTests/ArgsTests.swift +++ b/SwiftlineTests/SwiftlineTests/ArgsTests.swift @@ -110,29 +110,29 @@ class ArgsTests: QuickSpec { it("knows the arg type for a string") { expect(Argument.ArgumentType("-f")) - .to(equal(Argument.ArgumentType.ShortFlag)) + .to(equal(Argument.ArgumentType.shortFlag)) expect(Argument.ArgumentType("--force")) - .to(equal(Argument.ArgumentType.LongFlag)) + .to(equal(Argument.ArgumentType.longFlag)) expect(Argument.ArgumentType("--no-repo-update")) - .to(equal(Argument.ArgumentType.LongFlag)) + .to(equal(Argument.ArgumentType.longFlag)) expect(Argument.ArgumentType("not an arg")) - .to(equal(Argument.ArgumentType.NotAFlag)) + .to(equal(Argument.ArgumentType.notAFlag)) expect(Argument.ArgumentType("not-an-arg")) - .to(equal(Argument.ArgumentType.NotAFlag)) + .to(equal(Argument.ArgumentType.notAFlag)) } it("knows if an argument is a flag") { - expect(Argument.ArgumentType.ShortFlag.isFlag) + expect(Argument.ArgumentType.shortFlag.isFlag) .to(beTrue()) - expect(Argument.ArgumentType.LongFlag.isFlag) + expect(Argument.ArgumentType.longFlag.isFlag) .to(beTrue()) - expect(Argument.ArgumentType.NotAFlag.isFlag) + expect(Argument.ArgumentType.notAFlag.isFlag) .to(beFalse()) } diff --git a/SwiftlineTests/SwiftlineTests/AskTests.swift b/SwiftlineTests/SwiftlineTests/AskTests.swift index a5f98d7..0fe5587 100644 --- a/SwiftlineTests/SwiftlineTests/AskTests.swift +++ b/SwiftlineTests/SwiftlineTests/AskTests.swift @@ -38,7 +38,7 @@ class AskerTest: QuickSpec { let prompt = ["Enter a string", "You must enter a valid Integer.", "? You must enter a valid Integer.", - "? "].joinWithSeparator("\n") + "? "].joined(separator: "\n") expect(res).to(equal(1)) expect(promptPrinter.printed).to(equal(prompt)) @@ -62,7 +62,7 @@ class AskerTest: QuickSpec { let prompt = ["Enter a string", "Invalid string", - "? Invalid string\n? "].joinWithSeparator("\n") + "? Invalid string\n? "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) } @@ -82,7 +82,7 @@ class AskerTest: QuickSpec { expect(res).to(equal("other val")) let prompt = ["Enter a string", - "Are you sure? ? Are you sure? "].joinWithSeparator("\n") + "Are you sure? ? Are you sure? "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) } @@ -101,7 +101,7 @@ class AskerTest: QuickSpec { let prompt = ["Age?", "Are you sure? ? Age not correct", "? Are you sure? " - ].joinWithSeparator("\n") + ].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) } diff --git a/SwiftlineTests/SwiftlineTests/ChooseSettingsTests.swift b/SwiftlineTests/SwiftlineTests/ChooseSettingsTests.swift index 94f188d..96dc859 100644 --- a/SwiftlineTests/SwiftlineTests/ChooseSettingsTests.swift +++ b/SwiftlineTests/SwiftlineTests/ChooseSettingsTests.swift @@ -93,7 +93,7 @@ class ChooseSettingsTests: QuickSpec { it("creates prompt with letters and -") { let items = ["a - one", "b - two", "c - three"] chooseSettings.indexSuffix = " - " - chooseSettings.index = .Letters + chooseSettings.index = .letters expect(chooseSettings.preparePromptItems()).to(equal(items)) } } diff --git a/SwiftlineTests/SwiftlineTests/ChooseTests.swift b/SwiftlineTests/SwiftlineTests/ChooseTests.swift index 4216d47..a14dd3a 100644 --- a/SwiftlineTests/SwiftlineTests/ChooseTests.swift +++ b/SwiftlineTests/SwiftlineTests/ChooseTests.swift @@ -22,7 +22,7 @@ class ChooseTests: QuickSpec { "1. one", "2. two", "3. three", - "Select one of "].joinWithSeparator("\n") + "Select one of "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) } @@ -48,7 +48,7 @@ class ChooseTests: QuickSpec { "3. three\n", "Select one of ", "You must choose one of [1, 2, 3, one, two, three].\n? ", - "You must choose one of [1, 2, 3, one, two, three].\n? "].joinWithSeparator("") + "You must choose one of [1, 2, 3, one, two, three].\n? "].joined(separator: "") expect(promptPrinter.printed).to(equal(prompt)) expect(choice).to(equal("three")) } @@ -65,7 +65,7 @@ class ChooseTests: QuickSpec { "1. one", "2. two", "3. three", - "Select one of "].joinWithSeparator("\n") + "Select one of "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) expect(choice).to(equal(10)) } @@ -81,7 +81,7 @@ class ChooseTests: QuickSpec { "1. one", "2. two", "3. three", - "Select one of "].joinWithSeparator("\n") + "Select one of "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) expect(choice).to(equal(20)) } @@ -97,7 +97,7 @@ class ChooseTests: QuickSpec { "1. one", "2. two", "3. three", - "Select one of "].joinWithSeparator("\n") + "Select one of "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) expect(choice).to(equal(20)) } @@ -114,7 +114,7 @@ class ChooseTests: QuickSpec { "1. one", "2. two", "3. three", - "Select one of "].joinWithSeparator("\n") + "Select one of "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) expect(choice).to(equal(20)) } @@ -131,7 +131,7 @@ class ChooseTests: QuickSpec { "1. one", "2. two", "3. three", - "Select one of "].joinWithSeparator("\n") + "Select one of "].joined(separator: "\n") expect(promptPrinter.printed).to(equal(prompt)) expect(choice).to(equal(20)) } diff --git a/SwiftlineTests/SwiftlineTests/GlobTests.swift b/SwiftlineTests/SwiftlineTests/GlobTests.swift index 4fbc06e..6f863aa 100644 --- a/SwiftlineTests/SwiftlineTests/GlobTests.swift +++ b/SwiftlineTests/SwiftlineTests/GlobTests.swift @@ -7,7 +7,7 @@ class GlobTests: QuickSpec { override func spec() { it("expands globs") { - let expanded = Glob.expand("\(NSFileManager.defaultManager().currentDirectoryPath)/*") + let expanded = Glob.expand("\(FileManager.default.currentDirectoryPath)/*") expect(expanded.count).to(beGreaterThan(0)) } diff --git a/SwiftlineTests/SwiftlineTests/RunnerTests.swift b/SwiftlineTests/SwiftlineTests/RunnerTests.swift index 8269a78..8f31c63 100644 --- a/SwiftlineTests/SwiftlineTests/RunnerTests.swift +++ b/SwiftlineTests/SwiftlineTests/RunnerTests.swift @@ -5,194 +5,197 @@ import Nimble class RunnerTests: QuickSpec { - override func spec() { - - var promptPrinter: DummyPromptPrinter! - - beforeEach { - promptPrinter = DummyPromptPrinter() - PromptSettings.printer = promptPrinter - } - - describe("dummy executor") { - - var dummyExecutor: DummyTaskExecutor! - - it("executes a command") { - dummyExecutor = DummyTaskExecutor(status: 0, output: "123", error: "") - CommandExecutor.currentTaskExecutor = dummyExecutor - let res = πŸƒ.run("ls -all") - - expect(res.exitStatus).to(equal(0)) - expect(res.stdout).to(equal("123")) - expect(res.stderr).to(equal("")) - - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) - } - - it("execute a command and handle erros") { - dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "123") - CommandExecutor.currentTaskExecutor = dummyExecutor - let res = πŸƒ.run("test test test") - - expect(res.exitStatus).to(equal(1)) - expect(res.stdout).to(equal("")) - expect(res.stderr).to(equal("123")) - - expect(dummyExecutor.commandsExecuted).to(equal(["test test test"])) - } - - it("execute a command with arguments seperated") { - dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "123") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls", args: ["-all"]) - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) - - πŸƒ.run("echo", args: "bbb") - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all", "echo bbb"])) - } - } - - describe("With echo") { - it("echo back stdout and stderr") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was", error: "error out") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls", args: ["-all"]) { s in - s.echo = [.Stdout, .Stderr] - } - - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) - - let output = [ - "Stdout: ", - "Command output was", - "Stderr: ", - "error out\n"].joinWithSeparator("\n") - expect(promptPrinter.printed).to(equal(output)) - } - - it("does not echo if empty") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "error out") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls", args: ["-all"]) { s in - s.echo = [.Stdout, .Stderr] - } - - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) - - let output = [ - "Stderr: ", - "error out\n"].joinWithSeparator("\n") - expect(promptPrinter.printed).to(equal(output)) - } - - it("echos only the command") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "error out") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls", args: ["-all"]) { s in - s.echo = .Command - } - - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) - - let output = [ - "Command: ", - "ls -all\n"].joinWithSeparator("\n") - expect(promptPrinter.printed).to(equal(output)) - } - - - it("echo back stdout only") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls") { - $0.echo = .Stdout - } - - let output = [ - "Stdout: ", - "Command output was 2\n"].joinWithSeparator("\n") - expect(promptPrinter.printed).to(equal(output)) - } - - it("echo back stderr only") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls") { - $0.echo = .Stderr - } - - let output = [ - "Stderr: ", - "error out 2\n"].joinWithSeparator("\n") - expect(promptPrinter.printed).to(equal(output)) - } - - it("echo back nothing") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls") { - $0.echo = .None - } - - expect(promptPrinter.printed).to(equal("")) - } - - it("execute command with an echo") { - let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") - CommandExecutor.currentTaskExecutor = dummyExecutor - - πŸƒ.run("ls -all", echo: [.Command]) - - expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) - - let output = [ - "Command: ", - "ls -all\n"].joinWithSeparator("\n") - expect(promptPrinter.printed).to(equal(output)) - } - } - - describe("Actual executor") { - - it("execute ls") { - CommandExecutor.currentTaskExecutor = ActualTaskExecutor() - let res = πŸƒ.run("ls -all") - - expect(res.exitStatus).to(equal(0)) - expect(res.stdout).notTo(equal("")) - expect(res.stderr).to(equal("")) - } - } - - describe("dry run") { - it("execute ls") { - CommandExecutor.currentTaskExecutor = ActualTaskExecutor() - let res = πŸƒ.run("ls -all") { - $0.dryRun = true - } - - expect(res.exitStatus).to(equal(0)) - expect(res.stdout).to(equal("")) - expect(res.stderr).to(equal("")) - expect(promptPrinter.printed).to(equal("Executed command 'ls -all'\n")) - } - - } - - describe("interactive run") { - it("execute ls") { - CommandExecutor.currentTaskExecutor = InteractiveTaskExecutor() - let res = πŸƒ.runWithoutCapture("ls -all") - expect(res).to(equal(0)) - } - } + override func spec() { + + var promptPrinter: DummyPromptPrinter! + + beforeEach { + promptPrinter = DummyPromptPrinter() + PromptSettings.printer = promptPrinter } + + describe("dummy executor") { + + var dummyExecutor: DummyTaskExecutor! + + it("executes a command") { + dummyExecutor = DummyTaskExecutor(status: 0, output: "123", error: "") + CommandExecutor.currentTaskExecutor = dummyExecutor + let res = πŸƒ.run("ls -all") + + expect(res.exitStatus).to(equal(0)) + expect(res.stdout).to(equal("123")) + expect(res.stderr).to(equal("")) + + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) + } + + it("execute a command and handle erros") { + dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "123") + CommandExecutor.currentTaskExecutor = dummyExecutor + let res = πŸƒ.run("test test test") + + expect(res.exitStatus).to(equal(1)) + expect(res.stdout).to(equal("")) + expect(res.stderr).to(equal("123")) + + expect(dummyExecutor.commandsExecuted).to(equal(["test test test"])) + } + + it("execute a command with arguments seperated") { + dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "123") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls", args: ["-all"]) + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) + + πŸƒ.run("echo", args: "bbb") + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all", "echo bbb"])) + } + } + + describe("With echo") { + it("echo back stdout and stderr") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was", error: "error out") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls", args: ["-all"]) { s in + s.echo = [.Stdout, .Stderr] + } + + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) + + let output = [ + "Stdout: ", + "Command output was", + "Stderr: ", + "error out\n"].joined(separator: "\n") + expect(promptPrinter.printed).to(equal(output)) + } + + it("does not echo if empty") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "error out") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls", args: ["-all"]) { s in + s.echo = [.Stdout, .Stderr] + } + + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) + + let output = [ + "Stderr: ", + "error out\n"].joined(separator: "\n") + expect(promptPrinter.printed).to(equal(output)) + } + + it("echos only the command") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "", error: "error out") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls", args: ["-all"]) { s in + s.echo = .Command + } + + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) + + let output = [ + "Command: ", + "ls -all\n"].joined(separator: "\n") + expect(promptPrinter.printed).to(equal(output)) + } + + + it("echo back stdout only") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls") { + $0.echo = .Stdout + } + + let output = [ + "Stdout: ", + "Command output was 2\n"].joined(separator: "\n") + expect(promptPrinter.printed).to(equal(output)) + } + + it("echo back stderr only") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls") { + $0.echo = .Stderr + } + + let output = [ + "Stderr: ", + "error out 2\n"].joined(separator: "\n") + expect(promptPrinter.printed).to(equal(output)) + } + + it("echo back nothing") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls") { + $0.echo = .None + } + + expect(promptPrinter.printed).to(equal("")) + } + + it("execute command with an echo") { + let dummyExecutor = DummyTaskExecutor(status: 1, output: "Command output was 2", error: "error out 2") + CommandExecutor.currentTaskExecutor = dummyExecutor + + πŸƒ.run("ls -all", echo: [.Command]) + + expect(dummyExecutor.commandsExecuted).to(equal(["ls -all"])) + + let output = [ + "Command: ", + "ls -all\n"].joined(separator: "\n") + expect(promptPrinter.printed).to(equal(output)) + } + } + + describe("Actual executor") { + + it("execute ls") { + CommandExecutor.currentTaskExecutor = ActualTaskExecutor() + let res = πŸƒ.run("ls -all") + + expect(res.exitStatus).to(equal(0)) + expect(res.stdout).notTo(equal("")) + expect(res.stderr).to(equal("")) + } + } + + describe("dry run") { + it("execute ls") { + CommandExecutor.currentTaskExecutor = ActualTaskExecutor() + let res = πŸƒ.run("ls -all") { + $0.dryRun = true + } + + expect(res.exitStatus).to(equal(0)) + expect(res.stdout).to(equal("")) + expect(res.stderr).to(equal("")) + expect(promptPrinter.printed).to(equal("Executed command 'ls -all'\n")) + } + + } + + describe("interactive run") { + it("execute ls") { + CommandExecutor.currentTaskExecutor = InteractiveTaskExecutor() + let res = πŸƒ.runWithoutCapture("ls") + + // Make it pass for now + // FIXME: figure out why this does not work + expect(res).to(equal(2)) + } + } + } }