Skip to content

Update index.js

Update index.js #17

Workflow file for this run

# 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: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x' # Use the Node.js version your project requires
- name: Install dependencies
run: npm install
- name: Run bot to check for errors
env:
CI_TEST: true
run: |
node index.js &
sleep 10
pkill -f "node index.js"
- name: Verify no runtime errors
run: echo "Bot started successfully without errors"