 
     preloadedView.unload {
     }, {
-      onSuccess: -> alert "unload call success"
-      onFailure: (error)  -> alert "failed to unload: " + error.errorDescription
+      onSuccess: -> navigator.notification.alert "unload call success"
+      onFailure: (error)  -> navigator.notification.alert "failed to unload: " + error.errorDescription
     }
 
   @testPreloadThisAndOpen: () ->

  #event tests
  @testCreatedEvent: ->
    eventHandler = steroids.view.on 'created', (event) ->
      alert "created event -> eventName: #{event.name} webview.location: #{event.webview.location}"

    alert "event listener added"

  @testPreloadedEvent: ->
    eventHandler = steroids.view.on 'preloaded', (event) ->
      alert "preloaded event -> eventName: #{event.name} webview.location: #{event.webview.location}"

    alert "event listener added"

  @testUnloadedEvent: ->
    eventHandler = steroids.view.on 'unloaded', (event) ->
      alert "unloaded event -> eventName: #{event.name} webview.location: #{event.webview.location}"

    alert "event listener added"


  @testOffAllEvents: ->

          steroids.logger.log "testing replaceToRoot"
          @testReplaceToRoot()
        when "testAlert"
          navigator.notification.alert "I should not freeze the app!"

  @testReplaceToRoot: ->
    rootView = new steroids.views.WebView {
