     func testNetworkRespondsWithInvalidJSONDoesNotNotifyDelegateLoadWasSuccessful() {
         let invalidJSONAdapter = SuccessfulNetworkAdapter(contentsOfJSONFile: "MalformedWeasylHomepageResponse")
         let capturingHomepageFeedDelegate = CapturingHomepageFeedDelegate()
+        let feed = WeasylHomepageFeed()
         feed.loadFeed(networkAdapter: invalidJSONAdapter, delegate: capturingHomepageFeedDelegate)
 
         XCTAssertFalse(capturingHomepageFeedDelegate.wasNotifiedDidFinishLoading)

        let titleForFirstItemInJSON = ":CO: ChaiFennec"
        let validHomepageAdapter = SuccessfulNetworkAdapter(contentsOfJSONFile: "ValidWeasylHomepageResponse")
        let capturingHomepageFeedDelegate = CapturingHomepageFeedDelegate()
        feed.loadFeed(networkAdapter: validHomepageAdapter, delegate: capturingHomepageFeedDelegate)

        XCTAssertEqual(titleForFirstItemInJSON, capturingHomepageFeedDelegate.capturedResults?.first?.title)

        let json = try! JSONSerialization.data(withJSONObject: unexpectedStructure, options: .prettyPrinted)
        let unexpectedJSONAdapter = SuccessfulNetworkAdapter(data: json)
        let capturingHomepageFeedDelegate = CapturingHomepageFeedDelegate()
        let feed = WeasylHomepageFeed()
        feed.loadFeed(networkAdapter: unexpectedJSONAdapter, delegate: capturingHomepageFeedDelegate)

        XCTAssertTrue(capturingHomepageFeedDelegate.wasNotifiedFeedDidFailToLoad)
