9163dfe93c
TBR=rnystrom Review URL: https://codereview.chromium.org//10928216 git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12413 260f80e4-7a28-3924-810f-c04153c831b5
23 lines
599 B
Dart
23 lines
599 B
Dart
#library('AudioElementTest');
|
|
#import('../../pkg/unittest/unittest.dart');
|
|
#import('../../pkg/unittest/html_config.dart');
|
|
#import('dart:html');
|
|
|
|
main() {
|
|
|
|
useHtmlConfiguration();
|
|
|
|
test('constructorTest1', () {
|
|
var audio = new AudioElement(); // would be new Audio() in JS
|
|
Expect.isTrue(audio != null);
|
|
Expect.isTrue(audio is AudioElement);
|
|
});
|
|
|
|
test('constructorTest2', () {
|
|
var audio = new AudioElement('hahaURL');
|
|
Expect.isTrue(audio != null);
|
|
Expect.isTrue(audio is AudioElement);
|
|
Expect.isTrue(audio.src.indexOf('hahaURL') >= 0);
|
|
});
|
|
}
|