Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
tomfrenken committed Aug 13, 2024
1 parent 176a916 commit 88f0801
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
7 changes: 5 additions & 2 deletions global-test-setup.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
export default async function mockAiCoreEnvVariable() {
/**
* This file is used to mock the environment variables that are required for the tests.
*/
export default async function mockAiCoreEnvVariable(): Promise<void> {
const aiCoreServiceCredentials = {
clientid: 'clientid',
clientsecret: 'clientsecret',
url: 'https://example.authentication.eu12.hana.ondemand.com',
serviceurls: {
AI_API_URL: 'https://api.ai.ml.hana.ondemand.com'
}
}
};
process.env['aicore'] = JSON.stringify(aiCoreServiceCredentials);
}
7 changes: 5 additions & 2 deletions global-test-teardown.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
export default async function tearDown() {
/**
* This file is used to run code after all tests have been run.
*/
export default async function tearDown(): Promise<void> {
delete process.env.aicore;
}
}
2 changes: 1 addition & 1 deletion tsconfig.test.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
},
"include": ["packages/**/*.ts", "test-util/**/*.ts"],
"exclude": ["dist/**/*", "node_modules/**/*"]
}
}

0 comments on commit 88f0801

Please sign in to comment.