 import JSQNotificationObserverKit
 
 
+
 // MARK: Fakes
 
-class TestSender {
+class TestSender: Equatable {
     let sender = NSUUID().UUIDString
 }
 
-struct TestValue {
+struct TestValue: Equatable {
     let value = NSUUID().UUIDString
 }
 
-
-// MARK: Test case
-
-class JSQNotificationObserverKitTests: XCTestCase {
-
-    func test_Example_NotificationEmptyTuple_WithoutSender() {
+func ==(lhs: TestSender, rhs: TestSender) -> Bool {
+    return lhs.sender == rhs.sender
+}
+
+func ==(lhs: TestValue, rhs: TestValue) -> Bool {
+    return lhs.value == rhs.value
+}
+
+
+
+// MARK: Test cases
+
+let timeout = NSTimeInterval(3)
+
+
+class NotificationObserverTests: XCTestCase {
+
+    func test_ThatNotificationIsPostedAndReceived_WithEmptyTupleAndNoSender() {
 
         // GIVEN: a notification
         let notif = Notification<Void, AnyObject>(name: "Notification")

            userInfo: nil)

        // THEN: the observer receives the notification and executes its handler
        self.waitForExpectationsWithTimeout(2, handler: { (error) in
            XCTAssertNil(error, "Expectation should not error")
        })
    }

    func test_ThatObserverUnregistersForNotificationsOnDeinit_WithValueSenderHandler() {

        // GIVEN: a notification and observer
        let fakeValue = TestValue()


        XCTAssertNotNil(observer)

        // WHEN: the notification is posted with an empty tuple and no sender
        postNotification(notif, value: ())

        // THEN: the observer receives the notification and executes its handler
        self.waitForExpectationsWithTimeout(timeout, handler: { (error) in
            XCTAssertNil(error, "Expectation should not error")
        })
    }

    func test_ThatNotificationIsPostedAndReceived_WithUserInfoAndSender() {

        // GIVEN: a userInfo dictionary
        let userInfo = ["someKey": 100, "anotherKey": NSDate()]

        // GIVEN: a notification
        let notif = Notification<[String: NSObject], NotificationObserverTests>(name: "ExampleNotification", sender: self)

        let expect = self.expectationWithDescription("\(__FUNCTION__)")

