Skip to content

Instantly share code, notes, and snippets.

@alanf
Last active April 10, 2017 19:50
Show Gist options
  • Save alanf/b39a89337b57cfb81a00142ea63f7c74 to your computer and use it in GitHub Desktop.
Save alanf/b39a89337b57cfb81a00142ea63f7c74 to your computer and use it in GitHub Desktop.
func testLogBreadcrumbs() {
let recorder = FakeRecorder()
let logger = BreadcrumbLogger(recorder: recorder)
let breadcrumbs = createBreadcrumbs()
logger.logBreadcrumbs(breadcrumbs: breadcrumbs)
let firstRecord = JSON(data: recorder.testRecords[0])
XCTAssertEqual(firstRecord["breadcrumb"], "testdata")
// ... Additional checks omitted for brevity ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment