# Testing a chitchat.js project

We can use external Alexa test framework to test our skill.

npm install alexa-skill-test-framework --save-dev

Let's say you defined your skill like:

import { ax } from "@chitchatjs/alexa";

const state = ax
  .block(ax.say("Hello World"))

const skill = ax

export = ax.dialogManager(skill).exports();

Define your test :

import "mocha";
import skill from "../src/index";
const alexaTest = require("alexa-skill-test-framework");

describe("Hello World Skill", function() {
  alexaTest.initialize(skill, "appId", "userId", "deviceId");

      request: alexaTest.getLaunchRequest(),
      says: "Hello World",
      shouldEndSession: true,

Run tests:

  Hello World Skill
    ✓ returns the correct responses

  1 passing (7ms)

See end to end working tests here(opens new window) .