Sergiu Miclea 6 anni fa
parent
commit
b7927d7dec

+ 7 - 0
src/components/organisms/EndpointDetailsContent/test.jsx

@@ -21,6 +21,8 @@ import moment from 'moment'
 import TW from '../../../utils/TestWrapper'
 import EndpointDetailsContent from '.'
 
+import configLoader from '../../../utils/Config'
+
 const wrap = props => new TW(shallow(
   // $FlowIgnore
   <EndpointDetailsContent usage={{ replicas: [], migrations: [] }}{...props} />
@@ -46,6 +48,11 @@ let connectionInfo = {
 }
 
 describe('EndpointDetailsContent Component', () => {
+  beforeAll(() => {
+    // $FlowIgnore
+    configLoader.config = { passwordFields: [] }
+  })
+
   it('renders endpoint details', () => {
     let wrapper = wrap({ item })
     expect(wrapper.find('name').prop('value')).toBe(item.name)

+ 7 - 0
src/components/organisms/WizardOptions/test.jsx

@@ -19,6 +19,8 @@ import { shallow } from 'enzyme'
 import TW from '../../../utils/TestWrapper'
 import WizardOptions from '.'
 
+import configLoader from '../../../utils/Config'
+
 const wrap = props => new TW(shallow(
   // $FlowIgnore
   <WizardOptions {...props} />
@@ -56,6 +58,11 @@ let fields = [
 ]
 
 describe('WizardOptions Component', () => {
+  beforeAll(() => {
+    // $FlowIgnore
+    configLoader.config = { passwordFields: [] }
+  })
+
   it('has description and required field in simple tab', () => {
     let wrapper = wrap({ fields, selectedInstances: [], wizardType: 'migration' })
     expect(wrapper.findPartialId('field-').length).toBe(3)