Skip to content
Extraits de code Groupes Projets
Valider b1dac3e2 rédigé par Florian Staudacher's avatar Florian Staudacher
Parcourir les fichiers

don't test for opacity but for the selector

parent 0aa845f8
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -23,23 +23,11 @@ describe("app.views.ServicesSelector", function(){
// this tests the crazy css we have in a bassackwards way
// check out toggling the services on the new publisher and make sure it works if you change stuff.
it("selects the checkbox when the image is clicked", function(){
waitsFor(function() {
return ($("label[for=service_toggle_facebook] img").css("opacity") < 0.8);
});
expect($("label[for=service_toggle_facebook] img").is(".magic-service-selector input:not(:checked) + label img")).toBeTruthy();
this.view.$("input[value='facebook']").select()
runs(function() {
expect($("label[for=service_toggle_facebook] img").css("opacity")).toBeLessThan(0.8) //floating point weirdness, be safe.
this.view.$("input[value='facebook']").select()
});
waitsFor(function(){
return $("label[for=service_toggle_facebook] img").css("opacity") == 1
});
runs(function() {
expect($("label[for=service_toggle_facebook] img").css("opacity")).toBeGreaterThan(0.8) //floating point weirdness, be safe.
});
})
expect($("label[for=service_toggle_facebook] img").is(".magic-service-selector input:not(:checked) + label img")).toBeFalsy();
});
});
describe("askForAuth", function() {
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter