mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-08-21 04:45:17 +00:00
Use es6 notation in tests
This commit is contained in:
@@ -6,7 +6,7 @@ const it = global.it;
|
||||
describe("Position of modules", function () {
|
||||
helpers.setupTimeout(this);
|
||||
|
||||
var app = null;
|
||||
let app = null;
|
||||
|
||||
describe("Using helloworld", function () {
|
||||
after(function () {
|
||||
@@ -25,14 +25,11 @@ describe("Position of modules", function () {
|
||||
});
|
||||
});
|
||||
|
||||
var positions = ["top_bar", "top_left", "top_center", "top_right", "upper_third", "middle_center", "lower_third", "bottom_left", "bottom_center", "bottom_right", "bottom_bar", "fullscreen_above", "fullscreen_below"];
|
||||
const positions = ["top_bar", "top_left", "top_center", "top_right", "upper_third", "middle_center", "lower_third", "bottom_left", "bottom_center", "bottom_right", "bottom_bar", "fullscreen_above", "fullscreen_below"];
|
||||
|
||||
var position;
|
||||
var className;
|
||||
for (var idx in positions) {
|
||||
position = positions[idx];
|
||||
className = position.replace("_", ".");
|
||||
it("show text in " + position, function () {
|
||||
for (const position of positions) {
|
||||
const className = position.replace("_", ".");
|
||||
it("should show text in " + position, function () {
|
||||
return app.client.$("." + className).then((result) => {
|
||||
return result.getText("." + className).should.eventually.equal("Text in " + position);
|
||||
});
|
||||
|
Reference in New Issue
Block a user