Commit 6535ca5d authored by Kushal Pandya's avatar Kushal Pandya Committed by Alexander Turinske

Update environment picker tests to be more readable

parent 4dd67a77
......@@ -98,9 +98,11 @@ describe('EnvironmentPicker component', () => {
});
it('disables the environments dropdown', () => {
expect(findDropdown().attributes('disabled')).toBe('true');
expect(findDropdown().attributes('text')).toBe(INVALID_CURRENT_ENVIRONMENT_NAME);
expect(findDropdown().attributes('loading')).toBe(undefined);
expect(findDropdown().attributes()).toMatchObject({
disabled: 'true',
text: INVALID_CURRENT_ENVIRONMENT_NAME,
loading: undefined,
});
});
it('has no dropdown items', () => {
......@@ -132,9 +134,11 @@ describe('EnvironmentPicker component', () => {
});
it('disables the environments dropdown', () => {
expect(findDropdown().attributes('disabled')).toBe('true');
expect(findDropdown().attributes('text')).toBe(LOADING_TEXT);
expect(findDropdown().attributes('loading')).toBe('true');
expect(findDropdown().attributes()).toMatchObject({
disabled: 'true',
text: LOADING_TEXT,
loading: 'true',
});
});
});
});
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment