villebro commented on a change in pull request #12352:
URL: https://github.com/apache/superset/pull/12352#discussion_r553965118



##########
File path: 
superset-frontend/spec/javascripts/explore/components/AdhocFilterEditPopover_spec.jsx
##########
@@ -47,6 +48,14 @@ const sqlAdhocFilter = new AdhocFilter({
   clause: CLAUSES.WHERE,
 });
 
+const faultiAdhocFilter = new AdhocFilter({
+  expressionType: null,
+  subject: null,
+  operator: '>',
+  comparator: '10',
+  clause: CLAUSES.WHERE,
+});

Review comment:
       ```suggestion
   const faultyAdhocFilter = new AdhocFilter({
     expressionType: null,
     subject: null,
     operator: '>',
     comparator: '10',
     clause: CLAUSES.WHERE,
   });
   ```

##########
File path: 
superset-frontend/spec/javascripts/explore/components/AdhocFilterEditPopover_spec.jsx
##########
@@ -97,6 +106,14 @@ describe('AdhocFilterEditPopover', () => {
     expect(wrapper.find(AdhocFilterEditPopoverSqlTabContent)).toExist();
   });
 
+  it('renders simple and sql tabs with ErrorBoundary instead of content', () 
=> {
+    const { wrapper } = setup({ adhocFilter: faultiAdhocFilter });
+    expect(wrapper.find(Tabs)).toExist();
+    expect(wrapper.find(Tabs.TabPane)).toHaveLength(2);
+    expect(wrapper.find(Button)).toHaveLength(2);
+    expect(wrapper.find(ErrorBoundary)).toHaveLength(2);
+  });

Review comment:
       ```suggestion
     it('renders simple and sql tabs with ErrorBoundary instead of content', () 
=> {
       const { wrapper } = setup({ adhocFilter: faultyAdhocFilter });
       expect(wrapper.find(Tabs)).toExist();
       expect(wrapper.find(Tabs.TabPane)).toHaveLength(2);
       expect(wrapper.find(Button)).toHaveLength(2);
       expect(wrapper.find(ErrorBoundary)).toHaveLength(2);
     });
   ```




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to