Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: Add GitHub Actions Workflows for Continuous Integration #17

Merged
merged 2 commits into from
May 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Pull Request Trigger Workflow

on:
pull_request:
branches:
- develop

jobs:
build-and-test:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '>=18'
- name: Install dependencies
run: npm install
- name: Run tests
run: npm run test -- --ci

19 changes: 19 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Push Trigger Workflow

on:
push:

jobs:
build:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '>=18'
- name: Install dependencies
run: npm install
- name: Run tests
run: npm run test -- --ci
18 changes: 18 additions & 0 deletions components/__tests__/__snapshots__/StyledText-test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`renders correctly 1`] = `
<Text
style={
[
{
"color": "#000",
},
[
undefined,
],
]
}
>
Snapshot test!
</Text>
`;
3 changes: 1 addition & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
"android": "expo start --android",
"ios": "expo start --ios",
"web": "expo start --web",
"test": "jest --watchAll"
"test": "jest",
"test:watch": "jest --watchAll",
"test:update": "jest --updateSnapshot",
"ci-start": "expo build:web"
},
"jest": {
"preset": "jest-expo"
Expand Down
Loading