Skip to content
This repository has been archived by the owner on Jun 9, 2024. It is now read-only.

Commit

Permalink
Add gpt engineer to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
waynehamadi committed Jul 9, 2023
1 parent d892649 commit df26274
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 5 deletions.
24 changes: 21 additions & 3 deletions .github/workflows/gpt-engineer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ on:
branches: [master]
push:
branches: [stable, master, ci-test*]
pull_request:
branches: [stable, master, ci-test*]

jobs:
regression-tests:
Expand Down Expand Up @@ -52,14 +54,30 @@ jobs:
poetry install --only main
poetry build
- name: Run regression tests
- name: Run regression tests (push)
if: ${{ github.event_name != 'pull_request' }}
run: |
cd agent/gpt-engineer
make install
source venv/bin/activate
pip install ../../dist/agbenchmark-0.1.0-py3-none-any.whl
agbenchmark start --maintain
pip install ../../dist/*.whl
if [ "${GITHUB_EVENT_NAME}" != "pull_request" ]; then
agbenchmark start --maintain
else
agbenchmark start --maintain --mock
agbenchmark start --improve --mock
agbenchmark start --mock
agbenchmark start --mock --category=retrieval
agbenchmark start --mock --category=regression
agbenchmark start --mock --category=interface
agbenchmark start --mock --category=code
agbenchmark start --mock --category=memory
agbenchmark start --mock --category=memory --category=code
fi
env:
GITHUB_EVENT_NAME: ${{ github.event_name }}
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}

- name: Upload logs as artifact
Expand Down
3 changes: 3 additions & 0 deletions agbenchmark/start_benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,9 @@ def start(category: str, maintain: bool, improve: bool, mock: bool) -> int:
if mock:
pytest_args.append("--mock")

# when used as a library, the pytest directory to execute is in the CURRENT_DIRECTORY
pytest_args.append(str(CURRENT_DIRECTORY))

return sys.exit(pytest.main(pytest_args))


Expand Down
2 changes: 1 addition & 1 deletion agent/Auto-GPT
2 changes: 1 addition & 1 deletion agent/gpt-engineer

0 comments on commit df26274

Please sign in to comment.