Updated unit test
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
64abd29257
commit
b50b30c792
|
@ -22,6 +22,22 @@ describe('Worker', () => {
|
|||
controller._worker = {id: 106};
|
||||
}));
|
||||
|
||||
describe('year() getter', () => {
|
||||
it(`should return the year number of the calendar date`, () => {
|
||||
expect(controller.year).toEqual(year);
|
||||
});
|
||||
});
|
||||
|
||||
describe('year() setter', () => {
|
||||
it(`should set the year of the calendar date`, () => {
|
||||
const previousYear = year - 1;
|
||||
controller.year = previousYear;
|
||||
|
||||
expect(controller.year).toEqual(previousYear);
|
||||
expect(controller.date.getFullYear()).toEqual(previousYear);
|
||||
});
|
||||
});
|
||||
|
||||
describe('started property', () => {
|
||||
it(`should return first day and month of current year`, () => {
|
||||
let started = new Date(year, 0, 1);
|
||||
|
|
Loading…
Reference in New Issue