mirror of
https://github.com/aljazceru/dev-gpt.git
synced 2026-01-01 12:54:20 +01:00
🧪3️⃣ test: level 3 fix no input
This commit is contained in:
@@ -138,7 +138,7 @@ template_generate_test = PromptTemplate.from_template(
|
||||
Write a single pytest case that tests the following scenario: '{test_description}'. In case the test scenario is not precise enough, test a general case without any assumptions.
|
||||
Start the test with an extensive comment about the test case. If gpt_3_5_turbo_api is used in the executor, then the test must not check the exact output of the executor as it is not deterministic.
|
||||
|
||||
Use the following import to import the function:
|
||||
You must use the following import to import the function:
|
||||
```
|
||||
from .implementation import func
|
||||
```
|
||||
@@ -221,9 +221,9 @@ You are given the following files:
|
||||
|
||||
{all_files_string}
|
||||
|
||||
Is this a PACKAGE_MANAGER dependency installation failure?
|
||||
1. Write down one bullet point on why it could be a PACKAGE_MANAGER dependency installation failure.
|
||||
2. Write down one bullet point on why it is unlikely that it is a PACKAGE_MANAGER dependency installation failure.
|
||||
Is this error happening because a PACKAGE_MANAGER package is missing or failed to install?
|
||||
1. Write down one bullet point on why the error might happen because a PACKAGE_MANAGER package is missing or failed to install.
|
||||
2. Write down one bullet point on why it is unlikely that the error happens because a PACKAGE_MANAGER package is missing or failed to install.
|
||||
3. Write down your final answer.
|
||||
4. Write down your final answer as json in the following format:
|
||||
**response.json**
|
||||
|
||||
@@ -26,10 +26,6 @@ def test_generation_level_0(tmpdir):
|
||||
assert generator.generate() == 0
|
||||
|
||||
|
||||
# fixture
|
||||
@pytest.fixture
|
||||
def tmpdir():
|
||||
return 'microservice'
|
||||
|
||||
|
||||
def test_generation_level_1(tmpdir):
|
||||
@@ -97,9 +93,11 @@ data = {{
|
||||
"url": "URL_OF_STORED_AUDIO_FILE"
|
||||
}}
|
||||
response = requests.post(url, headers=headers, data=data)
|
||||
print(response.text)
|
||||
assert response.status_code == 200
|
||||
print('This is the text from the audio file:', response.json()['text'])
|
||||
2. Summarize the text (~50 words) while still maintaining the key facts.
|
||||
3. Create an audio file of the summarized text using a tts library.
|
||||
4. Return the the audio file.
|
||||
Example input file: https://www.signalogic.com/melp/EngSamples/Orig/ENG_M.wav
|
||||
''',
|
||||
str(tmpdir) + 'microservice',
|
||||
@@ -147,5 +145,10 @@ Example input image: https://upload.wikimedia.org/wikipedia/commons/thumb/4/47/P
|
||||
)
|
||||
assert generator.generate() == 0
|
||||
|
||||
@pytest.fixture
|
||||
def tmpdir():
|
||||
return 'microservice'
|
||||
|
||||
|
||||
# further ideas:
|
||||
# Create a wrapper around google called Joogle. It modifies the page summary preview text of the search results to insert the word Jina as much as possible.
|
||||
|
||||
Reference in New Issue
Block a user