 
     modal = element(By.id("keyboard-modal"))
 
-    ptor.actions().sendKeys(protractor.Key.ESCAPE).perform()
+    browser.actions().sendKeys(protractor.Key.ESCAPE).perform()
 
     expect(modal.isDisplayed()).toBeFalsy()
 

    button = element(By.id("open-overlay-btn"))
    button.click()

    driver = protractor.getInstance().driver
    modal  = driver.findElement(By.id("overlay-modal"))
    driver.executeScript("arguments[0].click()", modal).then ->
      expect(modal.isDisplayed()).toBeFalsy()

describe "Mac Modal e2e test", ->
  beforeEach ->
    browser.get "/test/e2e/modal.html"
    browser.waitForAngular()

  it "should show the registered modal", ->
