Always resolve launching status

This commit is contained in:
Jake McDermott
2021-05-11 11:23:19 -04:00
parent a581e26414
commit 6e97020eae
2 changed files with 3 additions and 2 deletions

View File

@@ -78,6 +78,8 @@ function LaunchButton({ resource, children, history }) {
} }
} catch (err) { } catch (err) {
setError(err); setError(err);
} finally {
setIsLaunching(false);
} }
}; };

View File

@@ -155,8 +155,7 @@ describe('LaunchButton', () => {
const button = wrapper.find('button'); const button = wrapper.find('button');
await act(() => button.prop('onClick')()); await act(() => button.prop('onClick')());
wrapper.update(); wrapper.update();
expect(wrapper.find('button').prop('disabled')).toEqual(false);
expect(wrapper.find('button').prop('disabled')).toEqual(true);
}); });
test('should relaunch job correctly', async () => { test('should relaunch job correctly', async () => {