Skip to content

Commit

Permalink
Bump @types/jest from 29.2.4 to 29.2.5 (#114)
Browse files Browse the repository at this point in the history
<!--pre-commit.ci start-->
updates:
- [github.com/pre-commit/mirrors-eslint: v8.29.0 →
v8.31.0](pre-commit/mirrors-eslint@v8.29.0...v8.31.0)
<!--pre-commit.ci end-->

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: fabasoad <fabasoad@gmail.com>
  • Loading branch information
pre-commit-ci[bot] and fabasoad authored Jan 3, 2023
1 parent c01024d commit b427928
Show file tree
Hide file tree
Showing 7 changed files with 201 additions and 204 deletions.
6 changes: 4 additions & 2 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<!-- markdownlint-disable-file MD041 -->

Closes #{IssueNumber}

## Pull request checklist

Please check if your PR fulfills the following requirements:
Expand Down Expand Up @@ -50,3 +48,7 @@ Please check the type of change your PR introduces:

<!-- Any other information that is important to this PR such as screenshots of how the component looks before and after the change. -->
<!-- This document was adapted from the open-source [appium/appium](https://github.com/appium/appium/blob/master/.github/PULL_REQUEST_TEMPLATE.md) repository. -->

---

Closes #{IssueNumber}
24 changes: 4 additions & 20 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,35 +14,19 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get latest release tag
id: latest_release
run: |
latest_tag=$(curl --silent "https://api.github.com/repos/${{ github.repository }}/releases/latest" | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/')
echo "tag=${latest_tag}" >> $GITHUB_OUTPUT
shell: sh
- name: Get current release tag
id: current_release
run: echo "tag=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT
shell: bash
- name: Build changelog
- name: Get changelog
id: changelog
run: |
body=$(git log --pretty=oneline ${{ steps.latest_release.outputs.tag }}..${{ steps.current_release.outputs.tag }})
body="${body//'%'/'%25'}"
body="${body//$'\n'/'%0A'}"
body="${body//$'\r'/'%0D'}"
echo "body=${body}" >> $GITHUB_OUTPUT
shell: bash
uses: simbo/changes-since-last-release-action@v1
- name: Create release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ github.ref }}
name: ${{ steps.current_release.outputs.tag }}
name: ${{ github.ref_name }}
token: ${{ secrets.GITHUB_TOKEN }}
body: |
# Changelog
${{ steps.changelog.outputs.body }}
${{ steps.changelog.outputs.log }}
draft: false
prerelease: false
- name: Bump tags
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/functional-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@ jobs:
- provider: linguatools
lang: 'en-de'
source: Love
expected: Liebe
expected: 'Love'
api_key: N_A # pragma: allowlist secret
- provider: mymemory
lang: 'en|it'
source: Love
expected: 'Con affetto,'
expected: 'Lo adoro'
api_key: N_A # pragma: allowlist secret
- provider: mymemory
lang: 'en|pt'
source: Love
expected: 'Com gratidão,'
expected: 'Amor'
api_key: MYMEMORY_API_KEY # pragma: allowlist secret
- provider: funtranslations
lang: 'klingon'
Expand Down
18 changes: 8 additions & 10 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
default_install_hook_types: ["pre-commit", "pre-push"]
default_stages: ["commit"]
exclude: ^(.gitleaks\.toml|dist/.*\.js)$
exclude: ^(\.gitleaks\.toml|dist/.*\.js)$
minimum_pre_commit_version: 2.18.0
repos:
- repo: local
Expand All @@ -12,6 +12,13 @@ repos:
language: system
pass_filenames: false
verbose: true
- id: eslint
name: Lint
entry: yarn run lint
language: system
pass_filenames: false
verbose: true
stages: ["push"]
- id: test
name: Unit tests
entry: yarn test
Expand All @@ -35,15 +42,6 @@ repos:
hooks:
- id: snyk-test
stages: ["push"]
# TypeScript
- repo: https://github.com/pre-commit/mirrors-eslint
rev: v8.29.0
hooks:
- id: eslint
args: ['--fix']
files: \.[jt]sx?$
types: [file]
exclude: ^dist/.*\.js$
# Markdown
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.32.2
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,17 @@
"yandex-translate": "2.1.3"
},
"devDependencies": {
"@types/jest": "29.2.4",
"@typescript-eslint/eslint-plugin": "5.45.1",
"@typescript-eslint/parser": "5.45.1",
"@types/jest": "29.2.5",
"@typescript-eslint/eslint-plugin": "5.48.0",
"@typescript-eslint/parser": "5.48.0",
"@vercel/ncc": "0.36.0",
"dotenv": "16.0.3",
"eslint": "8.29.0",
"eslint": "8.31.0",
"eslint-config-google": "0.14.0",
"jest": "29.3.1",
"jest-circus": "29.3.1",
"mocha-param": "2.0.1",
"ts-jest": "29.0.3",
"typescript": "4.9.3"
"typescript": "4.9.4"
}
}
2 changes: 1 addition & 1 deletion src/__tests__/providers/MyMemoryProvider.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ describe('MyMemoryProvider', () => {
const provider: ProviderBase = new MyMemoryProvider(apiKey);
const translations = await provider.translate('Evening', 'en|pt');
expect(translations.length).toBeGreaterThan(0);
expect(translations[0]).toEqual('NOITE');
expect(translations[0]).toEqual('Noite');
});

test('should fail because of invalid lang', async () => {
Expand Down
Loading

0 comments on commit b427928

Please sign in to comment.