   # expected   - Expected value (null to test cookie is not set)
   # message    - Assert message if cookie does not have expected value
   cookie: (identifier, expected, message)->
+    if arguments.length == 1
+      expected = null
     actual = @browser.getCookie(identifier)
     message ||= "Expected cookie #{JSON.stringify(identifier)} to have the value '#{expected}', found '#{actual}'"
     assertMatch actual, expected, message

  # Asserts the selected element(s) has the expected value for the named style
  # property.
  style: (selector, style, expected, message)->
    elements = @browser.queryAll(selector)
    assert elements.length > 0, "Expected selector '#{selector}' to return one or more elements"
    for element in elements

  # Asserts that the global (window) property name has the expected value.
  global: (name, expected, message)->
    actual = @browser.window[name]
    if arguments.length == 1
      assert actual
    else
      message ||= "Expected global #{name} to have the value '#{expected}', found '#{actual}'"
      assertMatch actual, expected, message

  # Assert that browser prompted with a given message.
  prompted: (messageShown, message)->
