Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add unit testing and coverage support via jest
- Loading branch information
Showing
6 changed files
with
1,104 additions
and
38 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,12 @@ | |
.DS_Store | ||
node_modules | ||
|
||
coverage | ||
lib | ||
lib-esm | ||
umd | ||
typings | ||
|
||
## this is generated by `npm pack` | ||
*.tgz | ||
package |
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { Greeter } from '../Greeter'; | ||
|
||
describe(`Greeter`, () => { | ||
|
||
let greeter: Greeter; | ||
|
||
beforeEach(() => { | ||
greeter = new Greeter('World'); | ||
}); | ||
|
||
it(`should greet`, () => { | ||
|
||
const actual = greeter.greet(); | ||
const expected = 'Hello, World!'; | ||
|
||
expect(actual).toBe(expected); | ||
|
||
}); | ||
|
||
}); |
Oops, something went wrong.