Add: ユーザー辞書機能で対応する品詞の種類を拡充 #123
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
defaults: | |
run: | |
shell: bash | |
env: | |
PYTHON_VERSION: "3.11.9" | |
jobs: | |
test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- windows-2022 | |
- macos-13 | |
- macos-14 | |
- ubuntu-20.04 | |
steps: | |
- name: <Setup> Check out the repository | |
uses: actions/checkout@v4 | |
- name: <Setup> Prepare Python Runtime / Python Dependencies | |
uses: ./.github/actions/prepare_python | |
with: | |
python-version: ${{ env.PYTHON_VERSION }} | |
- name: <Setup> Install Poetry | |
run: python -m pip install poetry | |
- name: <Setup> Cache Poetry | |
uses: actions/cache@v4 | |
with: | |
path: ~/.cache/pypoetry | |
key: ${{ runner.os }}-${{ runner.arch }}-poetry-${{ hashFiles('**/poetry.lock') }} | |
- name: <Setup> Cache Engine Data | |
uses: actions/cache@v4 | |
with: | |
path: ~/.local/share/AivisSpeech-Engine | |
key: ${{ runner.os }}-${{ runner.arch }}-engine-data | |
- name: <Setup> Install Python dependencies | |
run: poetry install --with=dev | |
# - name: <Test> Validate poetry.lock | |
# run: | | |
# poetry lock --no-update | |
# git diff --exit-code | |
- name: <Test> Check format | |
run: PYTHONUTF8=1 poetry run task lint | |
- name: <Test> Test codes and coverage | |
run: poetry run coverage run --omit=test/* -m pytest | |
- name: <Deploy> Submit coverage results to Coveralls | |
if: matrix.os == 'ubuntu-20.04' | |
run: poetry run coveralls --service=github | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: <Test> Check licenses | |
run: poetry run task update-licenses | |
- name: <Test> Test names by checking typo | |
if: matrix.os == 'ubuntu-20.04' | |
uses: crate-ci/[email protected] | |
lint-builders: | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: <Setup> Check out the repository | |
uses: actions/checkout@v4 | |
- name: <Setup> Install ShellCheck | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y shellcheck | |
- name: <Test> Check shell files | |
run: git ls-files | grep -E '\.(ba)?sh' | xargs shellcheck | |
- name: <Test> Check workflow files | |
run: | | |
bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash) | |
./actionlint |