Keep timestamp replacements at the beginning

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2018-07-30 12:12:36 +02:00
parent 4bd7cb7a2d
commit 412002906f
No known key found for this signature in database
GPG key ID: 4C614C6ED2CDE6DF

View file

@ -137,7 +137,14 @@ module.exports = {
this.pageCompare.goto(`${config.urlChange}${route}`, {waitUntil: options.waitUntil})
]);
}
await this.pageBase.$eval('body', function (e) {
$('.live-relative-timestamp').removeClass('live-relative-timestamp').text('5 minutes ago');
$(':focus').blur();
});
await this.pageCompare.$eval('body', function (e) {
$('.live-relative-timestamp').removeClass('live-relative-timestamp').text('5 minutes ago');
$(':focus').blur();
});
var failed = null;
try {
await this.pageBase.bringToFront();
@ -147,6 +154,7 @@ module.exports = {
} catch (err) {
failed = err;
}
await this.awaitNetworkIdle(3);
await this.pageBase.$eval('body', function (e) {
$('.live-relative-timestamp').removeClass('live-relative-timestamp').text('5 minutes ago');
$(':focus').blur();
@ -155,7 +163,6 @@ module.exports = {
$('.live-relative-timestamp').removeClass('live-relative-timestamp').text('5 minutes ago');
$(':focus').blur();
});
await this.awaitNetworkIdle(3);
await Promise.all([
this.pageBase.screenshot({
path: `${this._outputDirectory}/${fileName}.base.png`,