Skip to content

fix(node): make url type constraint just a string #67

fix(node): make url type constraint just a string

fix(node): make url type constraint just a string #67

Workflow file for this run

name: Test & Lint
on:
push:
pull_request:
jobs:
test:
name: Test & Lint
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [22.x]
services:
typesense:
image: typesense/typesense:27.1
ports:
- 8108:8108
volumes:
- /tmp/typesense-data:/data
- /tmp/typesense-analytics:/analytics
env:
TYPESENSE_API_KEY: xyz
TYPESENSE_DATA_DIR: /data
TYPESENSE_ENABLE_CORS: true
TYPESENSE_ANALYTICS_DIR: /analytics
TYPESENSE_ENABLE_SEARCH_ANALYTICS: true
steps:
- name: Wait for Typesense
run: |
timeout 20 bash -c 'while [[ "$(curl -s -o /dev/null -w ''%{http_code}'' localhost:8108/health)" != "200" ]]; do sleep 1; done' || false
- uses: actions/checkout@v4
- name: Setup pnpm
uses: pnpm/action-setup@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: "pnpm"
- name: Install dependencies
run: pnpm install
- name: Run ESLint
run: pnpm lint
- name: Check types
run: pnpm type-check
- name: Run tests
run: pnpm test
- name: Upload test coverage
if: ${{ env.ACT != 'true' }}
uses: actions/upload-artifact@v4
with:
name: coverage-report-node-${{ matrix.node-version }}
path: coverage/
retention-days: 30