               observer?.emit(.ApplicationActivated, forElement: appElement)
             }
 
-            return initializeApp().then { appDelegate -> () in
-              let app = Swindler.Application(delegate: appDelegate)
-              expect(app.isFrontmost.value).toEventually(beTrue())
-            }
+            let app = Swindler.Application(delegate: initializeApp())
+            expect(app.isFrontmost.value).toEventually(beTrue())
           }
         }
 

      beforeEach { AdversaryObserver.reset() }

      typealias AppDelegate = OSXApplicationDelegate<TestUIElement, AdversaryApplicationElement, AdversaryObserver>
      func initializeApp() -> Promise<AppDelegate> {
        return AppDelegate.initialize(axElement: appElement, notifier: notifier)
      }

      context("when a property value changes right before observing it") {

        context("for a regular property") {
          it("is read correctly") { () -> Promise<Void> in
            appElement.attrs[.Frontmost] = false

            AdversaryObserver.onAddNotification(.ApplicationActivated) { _ in
              appElement.attrs[.Frontmost] = true
            }

            return initializeApp().then { appDelegate -> () in
              let app = Swindler.Application(delegate: appDelegate)
              expect(app.isFrontmost.value).toEventually(beTrue())
            }
          }
        }


              observer.emit(.MainWindowChanged, forElement: windowElement)
            }

            let app = Swindler.Application(delegate: initializeApp())
            expect(app.mainWindow.value).toEventuallyNot(beNil())
          }
        }
