Skip to content

Commit

Permalink
CI: Opensearch Test added
Browse files Browse the repository at this point in the history
  • Loading branch information
Leo Park committed Dec 3, 2024
1 parent e915c68 commit 7868e4f
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
pull_request:

jobs:
tests:
elasticsearch_tests:
runs-on: ubuntu-latest
services:
es:
Expand Down Expand Up @@ -39,4 +39,3 @@ jobs:
- name: Run tests
run: python3 search_test.py --count=2000 --search_db_url=http://localhost:9200

41 changes: 41 additions & 0 deletions .github/workflows/opensearch_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: CI

on:
push:
branches:
- master
pull_request:

jobs:
opensearch_tests:
runs-on: ubuntu-latest
services:
es:
image: opensearchproject/opensearch:2
ports:
- 9200:9200
options: >-
--env discovery.type=single-node
--env "DISABLE_SECURITY_PLUGIN=true"
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.12

- name: Install dependencies
run: |
pip install --upgrade pip
pip install -r requirements.txt
- name: Wait for Opensearch
run: |
sleep 10
curl -s http://localhost:9200
- name: Run tests
run: python3 search_test.py --count=2000 --search_db_url=http://localhost:9200

0 comments on commit 7868e4f

Please sign in to comment.