Created
March 10, 2018 18:54
-
-
Save JitendraZaa/2f504149b4d9fac196daa24bf9de1e43 to your computer and use it in GitHub Desktop.
Jasmine Test method example
This file contains hidden or 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("Test Person Object", function(){ | |
| var per; | |
| beforeEach(function(){ | |
| per = new Person("Rudra","Zaa",20,"Black"); | |
| }); | |
| it("Get Correct Full Name", function(){ | |
| expect(per.name()).toEqual("Rudra Zaa"); | |
| }); | |
| it("Confirm if age changed",function(){ | |
| expect(per.getAge()).toEqual(20); | |
| per.changeAge(21); | |
| expect(per.getAge()).toEqual(21); | |
| }); | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment