An Ajax-based test was being run locally (which doesn't work).
This commit is contained in:
parent
0f7c89cd97
commit
6d03f9290e
1 changed files with 13 additions and 8 deletions
21
src/jquery/coreTest.js
vendored
21
src/jquery/coreTest.js
vendored
|
@ -159,7 +159,7 @@ test("index(Object)", function() {
|
|||
});
|
||||
|
||||
test("attr(String)", function() {
|
||||
expect(15);
|
||||
expect(13);
|
||||
ok( $('#text1').attr('value') == "Test", 'Check for value attribute' );
|
||||
ok( $('#text1').attr('type') == "text", 'Check for type attribute' );
|
||||
ok( $('#radio1').attr('type') == "radio", 'Check for type attribute' );
|
||||
|
@ -175,15 +175,20 @@ test("attr(String)", function() {
|
|||
|
||||
$('<a id="tAnchor5"></a>').attr('href', '#5').appendTo('#main'); // using innerHTML in IE causes href attribute to be serialized to the full path
|
||||
ok( $('#tAnchor5').attr('href') == "#5", 'Check for non-absolute href (an anchor)' );
|
||||
|
||||
stop();
|
||||
$.get("data/dashboard.xml", function(xml) {
|
||||
ok( $("locations", xml).attr("class") == "foo", "Check class attribute in XML document" );
|
||||
ok( $("location", xml).attr("for") == "bar", "Check for attribute in XML document" );
|
||||
start();
|
||||
});
|
||||
});
|
||||
|
||||
if ( location.protocol != "file:" ) {
|
||||
test("attr(String) in XML Files", function() {
|
||||
expect(2);
|
||||
stop();
|
||||
$.get("data/dashboard.xml", function(xml) {
|
||||
ok( $("locations", xml).attr("class") == "foo", "Check class attribute in XML document" );
|
||||
ok( $("location", xml).attr("for") == "bar", "Check for attribute in XML document" );
|
||||
start();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
test("attr(String, Function)", function() {
|
||||
expect(2);
|
||||
ok( $('#text1').attr('value', function() { return this.id })[0].value == "text1", "Set value from id" );
|
||||
|
|
Loading…
Reference in a new issue