Last active
December 28, 2015 20:52
-
-
Save alexanderfrankel/cda488aa75ef12ddcb5f to your computer and use it in GitHub Desktop.
testing-in-karma-initialization-test.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe('initialization', function() { | |
it('sets grades to default array of grades', function() { | |
expect($scope.grades).to.equal(["first", "second", "third"]); | |
}); | |
it('sets selectedGrade to null', function() { | |
expect($scope.selectedGrade).to.be.null; | |
}); | |
it('sets selectedStudents to empty array', function() { | |
expect($scope.selectedStudents).to.equal([]); | |
}); | |
it('sets allStudents to the index of students returned from the server', function() { | |
expect($scope.allStudents).to.equal([{name: "alex", grade: "third"}, | |
{name: "tom", grade: "second"}, | |
{name: "silvio", grade: "first"} | |
]); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment