You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by cc...@apache.org on 2018/10/15 19:52:22 UTC
[incubator-superset] 13/13: [cypress][dashboard][fetch] fix filter
test for fetch
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 da7d5f1d715023be98ee8dc36fc55aecfa014c79
Author: Chris Williams <ch...@airbnb.com>
AuthorDate: Mon Oct 15 12:51:53 2018 -0700
[cypress][dashboard][fetch] fix filter test for fetch
---
superset/assets/cypress/integration/dashboard/filter.js | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/superset/assets/cypress/integration/dashboard/filter.js b/superset/assets/cypress/integration/dashboard/filter.js
index fe236db..e0e65d8 100644
--- a/superset/assets/cypress/integration/dashboard/filter.js
+++ b/superset/assets/cypress/integration/dashboard/filter.js
@@ -40,11 +40,11 @@ export default () => describe('dashboard filter', () => {
.type('South Asia{enter}', { force: true });
cy.wait(aliases).then((requests) => {
- requests.forEach((request) => {
- const requestBody = request.request.body.substring('form_data='.length);
- const requestParams = JSON.parse(decodeURIComponent(requestBody));
+ requests.forEach((xhr) => {
+ const requestFormData = xhr.request.body;
+ const requestParams = JSON.parse(requestFormData.get('form_data'));
expect(requestParams.extra_filters[0])
- .deep.eq({ col: 'region', op: 'in', val: ['South+Asia'] });
+ .deep.eq({ col: 'region', op: 'in', val: ['South Asia'] });
});
});
});