Latest 0.3.3
Homepage https://github.com/RxSwiftCommunity/RxTestExt
License MIT
Platforms ios 9.0
Frameworks XCTest
Authors

CircleCI
pod

A collection of operators & tools not found in the core RxTest distribution.

Usage

RxTestExt can be used for common unit testing tasks like,

  • recording events from an observable into a Testable Observer
  • binding an array of recorded events (timeline) to an Observer or a Relay.
  • assert that recorded events match specific criteria.

For example:

func testSomething() {
   let source = scheduler.record(source: someObservable)
   scheduler.bind([next(10, "alpha"), completed(10)],
                  to: someObserver)
   scheduler.start()
   assert(source).next()
   assert(source).not.error()
}

Features

  • Scheduler subscription extensions
    • record observable events into a TestableObserver.
    • bind recorded events to an Observer or a Relay.
  • Rx Timeline matchers functions
    • assert TestableObserver recorded next events.
    • assert TestableObserver received error events.
    • assert TestableObserver received complete events.

Latest podspec

{
    "name": "RxTestExt",
    "version": "0.3.3",
    "summary": "A collection of operators & tools not found in the core RxTest distribution.",
    "description": "Provide developers with extensions for RxTest. The library includes a set of extensions for test schedulers and assertions on testable observers.",
    "homepage": "https://github.com/RxSwiftCommunity/RxTestExt",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "mosamer": "[email protected]"
    },
    "source": {
        "git": "https://github.com/RxSwiftCommunity/RxTestExt.git",
        "tag": "0.3.3"
    },
    "platforms": {
        "ios": "9.0"
    },
    "frameworks": "XCTest",
    "pushed_with_swift_version": "4.0",
    "subspecs": [
        {
            "name": "Core",
            "source_files": "RxTestExt/Core/*.{swift}",
            "dependencies": {
                "RxTest": [
                    "~> 4"
                ]
            }
        },
        {
            "name": "Relays",
            "source_files": "RxTestExt/Relays/*.{swift}",
            "dependencies": {
                "RxTestExt/Core": [],
                "RxCocoa": [
                    "~> 4"
                ]
            }
        }
    ]
}

Pin It on Pinterest

Share This