Skip to content

Instantly share code, notes, and snippets.

@soxjke
Last active October 26, 2017 15:01
Show Gist options
  • Save soxjke/754aba240865afb5f40991daf11f9ae2 to your computer and use it in GitHub Desktop.
Save soxjke/754aba240865afb5f40991daf11f9ae2 to your computer and use it in GitHub Desktop.
WeatherSpec - Step1
import Foundation
import Quick
import Nimble
@testable import Simple_Weather_App
class WeatherSpec: QuickSpec {
override func spec() {
let weatherJSON: [String: Any] = try! JSONSerialization.jsonObject(with: try! Data.init(contentsOf: Bundle.test.url(forResource: "Weather", withExtension: "json")!)) as! [String: Any]
describe("parsing") {
it("should parse weather") {
let weather = try? Weather(JSON: weatherJSON)
expect(weather).notTo(beNil())
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment