Skip to content

Commit

Permalink
Fixed tests and minor bug on renaming onFirstLink method
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriel Rode committed Feb 13, 2016
1 parent 7c02c73 commit 70747fd
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<html>
<head>
<title>Chain Em! - Test Page</title>
<title>Chain Em! - Demo Page</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script type="text/javascript" src="js/jquery.min.js"></script>
<script type="text/javascript" src="jquery.chainem.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion jquery.chainem.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
// .change
this.element
.on('change', function(){
link.executeFirstLink();
link.onFirstLink();
})
.on('chaining', function (){
link.onChaining();
Expand Down
7 changes: 2 additions & 5 deletions test/tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,6 @@ QUnit.module("last mode", {
},

'methods': {
'genero-remote': function(pv){
return pv;
},
'funcion': function(pv){
return daFuncion(pv.genero, pv.espectaculo);
}
Expand All @@ -93,6 +90,7 @@ QUnit.test("Local chaining (1 level)", function(assert){
assert.equal($('#funcion').val(), '1', "Selecciono el genero Accion (2). La funcion seleccionada debe ser Iron Man 3 (1)");
});


QUnit.asyncTest("Remote chaining (1 level)", function(assert){

// Selecciono Pelicula
Expand All @@ -107,6 +105,5 @@ QUnit.asyncTest("Remote chaining (1 level)", function(assert){
// Deberia ser La familia de mi novia
assert.equal($('#funcion').val(), '2', "Selecciono el espectaculo Pelicula (2) y el Genero Comedia (1). La funcion seleccionada debe ser 'La familia de mi novia' (2)");
QUnit.start();
}, 150 );

}, 150 );
});

0 comments on commit 70747fd

Please sign in to comment.