1 | import chai from 'chai';
|
2 | import msg from '../index.js';
|
3 | import pkgInfo from '../package.json';
|
4 |
|
5 | const expect = chai.expect;
|
6 |
|
7 | describe('Given an instance of my messenger', () => {
|
8 | describe('when I need the name', () => {
|
9 | it('should return the name', () => {
|
10 | expect(msg.name()).to.be.equal(pkgInfo.name);
|
11 | });
|
12 | });
|
13 | describe('when I need the version', () => {
|
14 | it('should return the version', () => {
|
15 | expect(msg.version()).to.be.equal(pkgInfo.version);
|
16 | });
|
17 | });
|
18 | });
|