Skip to content

Commit

Permalink
Merge pull request #858 from roramirez/check-week-number
Browse files Browse the repository at this point in the history
Check week number
  • Loading branch information
MichMich authored Apr 19, 2017
2 parents a3d4049 + dce8edf commit fa5b936
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
- Add test e2e `show title newsfeed` for newsfeed module.
- Add task to check configuration file.
- Add test check URLs of vendors.
- Add test of match current week number on clock module with showWeek configuration.
- Add test default modules present modules/default/defaultmodules.js.

### Updated
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
"devDependencies": {
"chai": "^3.5.0",
"chai-as-promised": "^6.0.0",
"current-week-number": "^1.0.7",
"grunt": "latest",
"grunt-eslint": "latest",
"grunt-jsonlint": "latest",
Expand Down
8 changes: 8 additions & 0 deletions tests/e2e/modules/clock_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,14 @@ describe("Clock module", function () {
return app.client.waitUntilWindowLoaded()
.getText(".clock .week").should.eventually.match(weekRegex);
});

it("shows week with correct number of week of year", function() {
const currentWeekNumber = require("current-week-number")();
const weekToShow = "Week " + currentWeekNumber;
return app.client.waitUntilWindowLoaded()
.getText(".clock .week").should.eventually.equal(weekToShow);
});

});

});

0 comments on commit fa5b936

Please sign in to comment.