Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- func testBartenderQueryForGivenEvent()
- {
- let expectation = self.expectationWithDescription("Wait for the bartender to be retrieved")
- Venue.queryForTestVenue { (venue, error) -> Void in
- let testVenue = venue as Venue
- testVenue.bartenders { (bartenders, error) -> Void in
- //NOTE: This casting is a workaround for an issue with Arrays in the Tests target
- //You must convert the array to [AnyObject]
- let theBartenders = bartenders as [AnyObject]
- let theBartender: AnyObject? = theBartenders.first
- XCTAssertNotNil(theBartender, "Bartender retrieved")
- expectation.fulfill()
- }
- }
- waitForExpectationsWithTimeout(kParseMaxTimeout, handler: nil)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement