Skip to content

Commit

Permalink
Simplify GitHub workflows by removing CI workflow and renaming jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
kojix2 committed Jan 31, 2025
1 parent e1728fc commit e8c3dbc
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 36 deletions.
25 changes: 0 additions & 25 deletions .github/workflows/ci.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- main

jobs:
build:
docs:
runs-on: ubuntu-latest

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- "v*.*.*"

jobs:
build:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: test_with_deepl_mock
name: test

on:
push:
Expand All @@ -7,12 +7,17 @@ on:
- cron: "51 3 * * 6" # Runs at 03:51, only on Saturday

jobs:
build:
test:
name: ubuntu
runs-on: ubuntu-latest
strategy:
fail-fast: false

env:
HTTP_PROXY: http://localhost:3001
DEEPL_SERVER_URL: http://localhost:3000
DEEPL_AUTH_KEY: mock

steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -49,17 +54,17 @@ jobs:
- name: Test deepl-mock server with curl
run: |
curl -X POST 'http://localhost:3001/v2/translate' \
--header 'Authorization: DeepL-Auth-Key [mock]' \
--header 'Content-Type: application/json' \
curl -X POST "${HTTP_PROXY}/v2/translate" \
--header "Authorization: DeepL-Auth-Key ${DEEPL_AUTH_KEY}" \
--header "Content-Type: application/json" \
--data '{"text":["proton beam"],"target_lang":"DE"}'
- name: Install dependencies
run: shards install --without-development

- name: Run tests
run: crystal spec -Ddeepl_mock
env:
DEEPL_SERVER_URL: http://localhost:3000
HTTP_PROXY: http://localhost:3001
DEEPL_AUTH_KEY: mock

- name: Stop deepl-mock server
if: always()
run: docker stop deepl-mock || true

0 comments on commit e8c3dbc

Please sign in to comment.