diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index fcf89450..2251f1cd 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -7,16 +7,23 @@ jobs:
     runs-on: ubuntu-latest
     steps:
       - uses: actions/checkout@v4
-      - name: Set up Node.js
-        uses: actions/setup-node@v4
+      - uses: actions/setup-node@v4
         with:
-          node-version: '21.x'  # Update this to the Node.js version you want to use
+          node-version: '21.x'
           registry-url: 'https://registry.npmjs.org'
-      - name: Install dependencies
-        run: |
-          npm install
-          npm run build
-      - name: Publish
-        run: npm publish
+      - run: npm ci
+      - run: npm test
+
+  publish-npm:
+    needs: build
+    runs-on: ubuntu-latest
+    steps:
+      - uses: actions/checkout@v4
+      - uses: actions/setup-node@v4
+        with:
+          node-version: '21.x'
+          registry-url: 'https://registry.npmjs.org'
+      - run: npm ci
+      - run: npm publish
         env:
           NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
\ No newline at end of file