diff --git a/awx/ui_next/src/components/CodeMirrorInput/VariablesDetail.jsx b/awx/ui_next/src/components/CodeMirrorInput/VariablesDetail.jsx index d89ea07b58..c4887363c2 100644 --- a/awx/ui_next/src/components/CodeMirrorInput/VariablesDetail.jsx +++ b/awx/ui_next/src/components/CodeMirrorInput/VariablesDetail.jsx @@ -14,10 +14,6 @@ function VariablesDetail({ value, label, rows }) { const [currentValue, setCurrentValue] = useState(value); const [error, setError] = useState(null); - if (!value) { - return null; - } - return ( <> ', () => { expect(input2.prop('mode')).toEqual('yaml'); expect(input2.prop('value')).toEqual('foo: bar\n'); }); + test('should render label and value= --- when there are no values', () => { + const wrapper = shallow(); + expect(wrapper.find('Styled(CodeMirrorInput)').length).toBe(1); + expect(wrapper.find('div.pf-c-form__label').text()).toBe('Variables'); + }); });