Skip to main content

Build and test Node.js applications

This page explains how to build and test Nodejs applications with FluentCI.

Before you begin

The instructions on this page assume that you are familiar with Nodejs. In addition:

  • Have your Node.js project handy, including package.json and test.js files.
  • Make sure your package.json file includes a build script and a test script.

Using the Node.js Plugin

You can use FluentCI to build and test Node.js applications using the node.js plugin, no need to install Node.js on your machine, FluentCI will handle everything for you.

The following commands can be used to build and test Node.js applications:

fluentci run --wasm nodejs test
fluentci run --wasm nodejs build

CI/CD pipeline integrations

The following examples show how to integrate FluentCI with popular CI providers to build and test Node.js applications:

ci.yml
name: ci
on:
push:
branches:
- main
jobs:
tasks:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Fluent CI
uses: fluentci-io/setup-fluentci@v5
- name: test
run: fluentci run --wasm nodejs test
- name: build
run: fluentci run --wasm nodejs build