Skip to content

Commit

Permalink
refact: reading key from env variable in unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
reply2future committed Apr 17, 2023
1 parent d7f9903 commit 746dd87
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/OpenAiTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

use Orhanerday\OpenAi\OpenAi;

$open_ai = new OpenAi('OPEN-AI-KEY');
$open_ai = new OpenAi(getenv('OPENAI_API_KEY'));

it('should handle simple completion using the new endpoint', function () use ($open_ai) {
$result = $open_ai->completion([
Expand Down

0 comments on commit 746dd87

Please sign in to comment.