BigW Consortium Gitlab

Commit f7efc5f8 by Dennis Tang

update tests

parent 2e4bea09
......@@ -47,7 +47,7 @@ describe('GkeProjectIdDropdown', () => {
});
it('returns project billing validation text', () => {
vm.isValidatingProjectBilling = true;
vm.setIsValidatingProjectBilling(true);
expect(vm.toggleText).toBe(LABELS.VALIDATING_PROJECT_BILLING);
});
......
......@@ -50,6 +50,19 @@ describe('GCP Cluster Dropdown Store Actions', () => {
});
});
describe('setIsValidatingProjectBilling', () => {
it('should set machine type', done => {
testAction(
actions.setIsValidatingProjectBilling,
true,
{ isValidatingProjectBilling: null },
[{ type: 'SET_IS_VALIDATING_PROJECT_BILLING', payload: true }],
[],
done,
);
});
});
describe('async fetch methods', () => {
window.gapi = gapi();
......@@ -74,10 +87,16 @@ describe('GCP Cluster Dropdown Store Actions', () => {
true,
{
selectedProject: selectedProjectMock,
selectedZone: '',
selectedMachineType: '',
projectHasBillingEnabled: null,
},
[{ type: 'SET_PROJECT_BILLING_STATUS', payload: true }],
[],
[
{ type: 'SET_ZONE', payload: '' },
{ type: 'SET_MACHINE_TYPE', payload: '' },
{ type: 'SET_PROJECT_BILLING_STATUS', payload: true },
],
[{ type: 'setIsValidatingProjectBilling', payload: false }],
done,
);
});
......
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