Skip to content

Commit

Permalink
revert
Browse files Browse the repository at this point in the history
  • Loading branch information
wayneseymour committed May 15, 2024
1 parent b8c0592 commit 575f85d
Showing 1 changed file with 3 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,14 @@
*/

import { FtrProviderContext } from '../../../ftr_provider_context';
import { RoleCredentials } from '../../../../shared/services';
export default function ({ getService }: FtrProviderContext) {
const supertestWithoutAuth = getService('supertestWithoutAuth');

export default function ({ getService }: FtrProviderContext) {
const esSupertest = getService('esSupertest');
const svlCommonApi = getService('svlCommonApi');
const svlUserManager = getService('svlUserManager');
let roleAuthc: RoleCredentials;

describe('Home', function () {
before(async () => {
roleAuthc = await svlUserManager.createApiKeyForRole('admin');
});
after(async () => {
await svlUserManager.invalidateApiKeyForRole(roleAuthc);
});
it('can request /', async () => {
const { body, status } = await supertestWithoutAuth
.get('/')
.set(svlCommonApi.getCommonRequestHeader())
.set(roleAuthc.apiKeyHeader)
.redirects(2);

const { body, status } = await esSupertest.get('/');
svlCommonApi.assertResponseStatusCode(200, status, body);
});
});
Expand Down

0 comments on commit 575f85d

Please sign in to comment.