Skip to content

Commit

Permalink
Fix screenshots Data Table and Tile Map.
Browse files Browse the repository at this point in the history
Fixes #5932
  • Loading branch information
LeeDr committed Jan 19, 2016
1 parent f68c78b commit 38578ad
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions test/functional/apps/visualize/_vertical_bar_chart.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,15 +86,11 @@ define(function (require) {
});

bdd.describe('vertical bar chart', function indexPatternCreation() {
var testSubName = 'VerticalBarChart';
var vizName1 = 'Visualization ' + testSubName;


bdd.it('should save and load, take screenshot', function pageHeader() {

var testSubName = 'VerticalBarChart';
common.debug('Start of test' + testSubName + 'Visualization');
var vizName1 = 'Visualization ' + testSubName;
// var remote = this.remote;

bdd.it('should save and load', function pageHeader() {
return visualizePage.saveVisualization(vizName1)
.then(function (message) {
common.debug('Saved viz message = ' + message);
Expand All @@ -112,15 +108,11 @@ define(function (require) {
.then(function waitForVisualization() {
return visualizePage.waitForVisualization();
})
.then(function takeScreenshot() {
common.debug('Take screenshot');
common.saveScreenshot('./screenshot-' + testSubName + '.png');
})
.catch(common.handleError(this));
});


bdd.it('should show correct chart', function pageHeader() {
bdd.it('should show correct chart, take screenshot', function pageHeader() {

var expectedChartValues = [37, 202, 740, 1437, 1371, 751, 188, 31, 42, 202, 683,
1361, 1415, 707, 177, 27, 32, 175, 707, 1408, 1355, 726, 201, 29
Expand All @@ -138,6 +130,10 @@ define(function (require) {
common.debug('data.length=' + data.length);
expect(data).to.eql(expectedChartValues);
})
.then(function takeScreenshot() {
common.debug('Take screenshot');
common.saveScreenshot('./screenshot-' + testSubName + '.png');
})
.catch(common.handleError(this));
});

Expand Down

0 comments on commit 38578ad

Please sign in to comment.