Internal
-
Used for observing tests and handling internal library errors.
See moreDeclaration
Swift
public class SwiftyMockyTestObserver : NSObject, XCTestObservation
-
[Internal] Used for handling fatal errors inside library.
See moreDeclaration
Swift
public struct FatalErrorUtil -
Declaration
Swift
public extension Optionalextension Optional: OptionalTypeextension Optional: ExpressibleByStringLiteral, ExpressibleByExtendedGraphemeClusterLiteral, ExpressibleByUnicodeScalarLiteral where Wrapped: ExpressibleByStringLiteralextension Optional: ExpressibleByIntegerLiteral where Wrapped: ExpressibleByIntegerLiteralextension Optional: ExpressibleByBooleanLiteral where Wrapped: ExpressibleByBooleanLiteralextension Optional: ExpressibleByFloatLiteral where Wrapped: ExpressibleByFloatLiteralextension Optional: ExpressibleByArrayLiteral where Wrapped: ExpressibleByArrayLiteralextension Optional: ExpressibleByDictionaryLiteral where Wrapped: ExpressibleByDictionaryLiteral, Wrapped.Key: Hashable -
[Internal] Generic Mock library errors
- notStubed: Calling method on mock, for which return value was not yet stubbed. DO NOT USE it as stub throw value!
Declaration
Swift
public enum MockError : Error -
[Internal] Possible Given products. Method can either return or throw an error (in general)
return: Return valuethrow: Thrown error value
Declaration
Swift
public enum StubProduct -
[Internal] Allows to reduce Mock.generated.swif size, by moving part of implementation here.
See moreDeclaration
Swift
open class StubbedMethod : WithStubbingPolicy -
[Internal] Fails flow with given message
Declaration
Swift
public func Failure(_ message: String) -> Swift.NeverParameters
messageFailure message
Return Value
Never
-
[internal] Assertion used by mocks and Verify methods
Declaration
Swift
public func MockyAssert( _ expression: @autoclosure () -> Bool, _ message: @autoclosure () -> String = "Verify failed", file: StaticString = #file, line: UInt = #line )Parameters
expressionExpression to assert on
messageMessage
fileFile name (levae default)
lineLine (levae default)
-
Protocol around Optional, allowing additional checks and features on
See moreParamaterwhere value is optional.Declaration
Swift
public protocol OptionalType : ExpressibleByNilLiteral
-
[Internal] used for marking that stubs have configurable policy
See moreDeclaration
Swift
public protocol WithStubbingPolicy : AnyObject
View on GitHub
Internal Reference