stub auth data for usage page (#12006) (#12009)

Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
This commit is contained in:
Vault Automation 2026-01-26 19:57:20 -05:00 committed by GitHub
parent 7fc3705838
commit b6349bf3d0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -12,12 +12,15 @@ module('Integration | Component | usage | Page::Usage', function (hooks) {
setupRenderingTest(hooks);
hooks.beforeEach(async function () {
this.authStub = sinon.stub(this.owner.lookup('service:auth'), 'authData');
this.authStub.value({ userRootNamespace: '' });
this.api = this.owner.lookup('service:api');
this.generateUtilizationReportStub = sinon.stub(this.api.sys, 'generateUtilizationReport').resolves({});
});
hooks.afterEach(function () {
this.generateUtilizationReportStub.restore();
this.authStub.restore();
});
test('it provides the correct fetch function to the dashboard component', async function (assert) {