spec/tests/notification.tests.js
author Ryan Willoughby <ryan.willoughby@nitobi.com>
Tue, 06 Jul 2010 11:31:19 -0700
changeset 0 54063d8b0412
permissions -rwxr-xr-x
initial commit of PhoneGap WRT framework, licensing and test code

Tests.prototype.NotificationTests = function() {	
	module('Notification (navigator.notification)');
	test("should exist", function() {
  		expect(1);
  		ok(navigator.notification != null, "navigator.notification should not be null.");
	});
	test("should contain a vibrate function", function() {
		expect(2);
		ok(typeof navigator.notification.vibrate != 'undefined' && navigator.notification.vibrate != null, "navigator.notification.vibrate should not be null.");
		ok(typeof navigator.notification.vibrate == 'function', "navigator.notification.vibrate should be a function.");
	});
	test("should contain a beep function", function() {
		expect(2);
		ok(typeof navigator.notification.beep != 'undefined' && navigator.notification.beep != null, "navigator.notification.beep should not be null.");
		ok(typeof navigator.notification.beep == 'function', "navigator.notification.beep should be a function.");
	});
};