Fix screenshot generation
This commit is contained in:
parent
cbcff2adee
commit
c0f3054781
4 changed files with 22 additions and 12 deletions
|
@ -1,4 +1,4 @@
|
|||
var width = 1024;
|
||||
var width = 1060;
|
||||
var height = 768;
|
||||
|
||||
var casper = require('casper').create({
|
||||
|
@ -76,11 +76,14 @@ casper.then(function() {
|
|||
this.capture(outputDir + 'repo-view.png');
|
||||
});
|
||||
|
||||
casper.then(function() {
|
||||
this.log('Generating repository changes screenshot.');
|
||||
|
||||
casper.thenClick('a[data-image="c3d710edbd3b"]', function() {
|
||||
this.waitForText('And 3048 more...', function() {
|
||||
this.capture(outputDir + 'image-view.png');
|
||||
});
|
||||
});
|
||||
|
||||
casper.thenClick('#current-image dd a', function() {
|
||||
casper.thenClick('.image-link', function() {
|
||||
this.waitForSelector('.result-count', function() {
|
||||
this.capture(outputDir + 'repo-changes.png', {
|
||||
top: 0,
|
||||
|
@ -89,7 +92,8 @@ casper.thenClick('#current-image dd a', function() {
|
|||
height: height
|
||||
});
|
||||
});
|
||||
})
|
||||
});
|
||||
|
||||
|
||||
casper.then(function() {
|
||||
this.log('Generating repository admin screenshot.');
|
||||
|
|
Reference in a new issue