OCMockitoSwift

PUBLISHED ON MAR 16, 2018 — PROJECT

Overview

OCMockitoSwift is OCMockito adapter for Swift, that allows to create and operate on mocks which are subclasses for NSObject.

Technical details

The adapter comes with two files:

  • OCMockitoSwiftAdapter.{h,m} – Objective-C code to provide Swift friendly interface that allows mocking, veryfing and stubbing
  • OCMockito.swift – set of global functions for Swift, e.g. mock() or verify()