superset-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ccwilli...@apache.org
Subject [incubator-superset] 12/13: [cypress][fetch] fix controls test for fetch
Date Mon, 15 Oct 2018 19:52:21 GMT
This is an automated email from the ASF dual-hosted git repository.

ccwilliams pushed a commit to branch chris--ajax-charts
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git

commit bedce49deec5d4e7a31244a8d9af7dd0e9441b0d
Author: Chris Williams <chris.williams@airbnb.com>
AuthorDate: Mon Oct 15 12:51:25 2018 -0700

    [cypress][fetch] fix controls test for fetch
---
 superset/assets/cypress/integration/dashboard/controls.js | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/superset/assets/cypress/integration/dashboard/controls.js b/superset/assets/cypress/integration/dashboard/controls.js
index cfde066..b79abf8 100644
--- a/superset/assets/cypress/integration/dashboard/controls.js
+++ b/superset/assets/cypress/integration/dashboard/controls.js
@@ -1,4 +1,5 @@
 import { WORLD_HEALTH_DASHBOARD, CHECK_DASHBOARD_FAVORITE_ENDPOINT } from './dashboard.helper';
+import readResponseBlob from '../../utils/readResponseBlob';
 
 export default () => describe('top-level controls', () => {
   let sliceIds = [];
@@ -61,8 +62,9 @@ export default () => describe('top-level controls', () => {
 
     cy.wait(forceRefreshRequests).then((xhrs) => {
       // is_cached in response should be false
-      xhrs.forEach((xhr) => {
-        expect(xhr.response.body.is_cached).to.equal(false);
+      xhrs.forEach(async (xhr) => {
+        const responseBody = await readResponseBlob(xhr.response.body);
+        expect(responseBody.is_cached).to.equal(false);
       });
     });
   });


Mime
View raw message