Update the screenshots to generate some action shots of the org.
This commit is contained in:
parent
d524559bce
commit
931ba5f9b9
3 changed files with 46 additions and 6 deletions
|
@ -49,3 +49,10 @@ running the tests:
|
|||
```
|
||||
STACK=test python -m unittest discover
|
||||
```
|
||||
|
||||
generating screenshots:
|
||||
|
||||
```
|
||||
cd screenshots
|
||||
casperjs screenshots.js --d
|
||||
```
|
|
@ -1,4 +1,4 @@
|
|||
var width = 993;
|
||||
var width = 1024;
|
||||
var height = 768;
|
||||
|
||||
var casper = require('casper').create({
|
||||
|
@ -12,12 +12,14 @@ var casper = require('casper').create({
|
|||
|
||||
var disableOlark = function() {
|
||||
casper.then(function() {
|
||||
this.waitForText('Contact us!', function() {
|
||||
this.waitForText('Chat with us!', function() {
|
||||
this.evaluate(function() {
|
||||
console.log(olark);
|
||||
window.olark.configure('box.start_hidden', true);
|
||||
window.olark('api.box.hide');
|
||||
});
|
||||
}, function() {
|
||||
// Do nothing, if olark never loaded we're ok with that
|
||||
});
|
||||
});
|
||||
};
|
||||
|
@ -27,6 +29,7 @@ var isDebug = !!options['d'];
|
|||
|
||||
var rootUrl = isDebug ? 'http://localhost:5000/' : 'https://quay.io/';
|
||||
var repo = isDebug ? 'complex' : 'r0';
|
||||
var org = isDebug ? 'buynlarge' : 'quay'
|
||||
|
||||
var outputDir = "screenshots/";
|
||||
|
||||
|
@ -42,11 +45,11 @@ casper.start(rootUrl + 'signin', function () {
|
|||
this.fill('.form-signin', {
|
||||
'username': 'devtable',
|
||||
'password': isDebug ? 'password': 'C>K98%y"_=54x"<',
|
||||
}, true);
|
||||
}, false);
|
||||
});
|
||||
|
||||
casper.then(function() {
|
||||
this.waitForText('Your Top Repositories');
|
||||
casper.thenClick('.form-signin button[type=submit]', function() {
|
||||
this.waitForText('Top Repositories');
|
||||
});
|
||||
|
||||
disableOlark();
|
||||
|
@ -90,4 +93,34 @@ casper.then(function() {
|
|||
this.capture(outputDir + 'repo-admin.png');
|
||||
});
|
||||
|
||||
casper.thenOpen(rootUrl + 'organizations/new/', function() {
|
||||
this.waitForText('Create');
|
||||
});
|
||||
|
||||
disableOlark();
|
||||
|
||||
casper.then(function() {
|
||||
this.capture(outputDir + 'org-create.png');
|
||||
});
|
||||
|
||||
casper.thenOpen(rootUrl + 'organization/' + org, function() {
|
||||
this.waitForSelector('.organization-name');
|
||||
});
|
||||
|
||||
disableOlark();
|
||||
|
||||
casper.then(function() {
|
||||
this.capture(outputDir + 'org-teams.png');
|
||||
});
|
||||
|
||||
casper.thenOpen(rootUrl + 'organization/' + org + '/admin', function() {
|
||||
this.waitForSelector('#repository-usage-chart');
|
||||
});
|
||||
|
||||
disableOlark();
|
||||
|
||||
casper.then(function() {
|
||||
this.capture(outputDir + 'org-admin.png');
|
||||
});
|
||||
|
||||
casper.run();
|
||||
|
|
|
@ -72,7 +72,7 @@
|
|||
<thead>
|
||||
<th>Plan</th>
|
||||
<th>Private Repositories</th>
|
||||
<th style="min-width: 64px">Price</th>
|
||||
<th style="min-width: 70px">Price</th>
|
||||
<th></th>
|
||||
</thead>
|
||||
|
||||
|
|
Reference in a new issue