Skip to content

test: fix Input component test expectations for border classes #94

test: fix Input component test expectations for border classes

test: fix Input component test expectations for border classes #94

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'
- name: Install dependencies
run: |
# Clean install to avoid npm cache issues
rm -rf node_modules package-lock.json
# Install without optional dependencies to avoid rollup native binaries issue
npm install --no-optional
# Install tsup dependencies explicitly
npm install tsup esbuild --force
- name: Install scc for code analysis
run: |
# Install scc (Source Code Counter) using Go
go install github.com/boyter/scc/v3@latest
echo "$HOME/go/bin" >> $GITHUB_PATH
export PATH="$HOME/go/bin:$PATH"
scc --version
- name: Run linting
run: npm run lint
- name: Run type check
run: npm run type-check
- name: Run tests with memory optimization
run: |
# Increase Node.js memory limit for tests
export NODE_OPTIONS="--max-old-space-size=4096"
npm run test:run
- name: Run tests with coverage
run: |
# Increase Node.js memory limit for coverage
export NODE_OPTIONS="--max-old-space-size=4096"
npm run test:coverage
- name: Build library
run: npm run build:lib
- name: Build demo (if demo files changed)
if: contains(github.event.head_commit.modified, 'demo/') || contains(github.event.head_commit.modified, 'src/') || contains(github.event.head_commit.modified, 'index.html')
run: npm run build:demo
- name: Run code analysis
run: |
export PATH="$HOME/go/bin:$PATH"
npm run analyze:json > code-analysis.json
- name: Upload code analysis results
uses: actions/upload-artifact@v4
with:
name: code-analysis
path: code-analysis.json
- name: Upload coverage reports
uses: actions/upload-artifact@v4
with:
name: coverage
path: coverage/
- name: Upload demo build (if built)
if: contains(github.event.head_commit.modified, 'demo/') || contains(github.event.head_commit.modified, 'src/') || contains(github.event.head_commit.modified, 'index.html')
uses: actions/upload-artifact@v4
with:
name: demo-build-${{ github.sha }}
path: dist-demo/