Skip to content
Merged
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
41 changes: 41 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Node.js CI

on:
push:
branches: [ "main", "CI_CD" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [ 22.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: |
echo "TZ=UTC" >> .env
echo "PORT=8000" >> .env
echo "HOST=localhost" >> .env
echo "LOG_LEVEL=info" >> .env
echo "NODE_ENV=development" >> .env
echo "SESSION_DRIVER=cookie" >> .env
echo "MONGO_URI=mongodb://localhost:27017/citium" >> .env
echo "JWT_SECRET=$(openssl rand -base64 32)" >> .env
- run: npm ci
- run: node ace generate:key
- run: node ace test
Loading