Skip to content

Testing Xatkit

Gwendal Daniel edited this page Mar 16, 2021 · 2 revisions

Each Xatkit project can be tested individually, to do so navigate to the root of the project you want to test and run the following command:

mvn test

Testing Xatkit Runtime

Most of our tests are located in Xatkit Runtime. This is the place where we test Intent Recognition Providers such as DialogFlow or NLP.js, as well as our processors.

You'll need a bit of configuration to run all the tests in Xatkit Runtime:

  • Create the file test-variables.properties in xatkit-runtime/src/test/resources, and fill the following contents
xatkit.dialogflow.projectId = <Your DialogFlow project ID>
xatkit.dialogflow.language = <The language of your DialogFlow agent>
xatkit.dialogflow.credentials.path = <Path to your DialogFlow credentials file>
xatkit.perspectiveapi.apiKey = <Your Perspective API key>
xatkit.nlpjs.agentId = <The name of the NLP.js agent>
xatkit.nlpjs.server = <The URL of the NLP.js server>
xatkit.nlpjs.basicauth.username = <The username for the basic authentication of the NLP.js server>
xatkit.nlpjs.basicauth.password = <The password for the basic authentication of the NLP.js server>

📚 You can find an empty version of the test-variables.properties file here.

  • Add your DialogFlow credentials (JSON key) in xatkit-runtime/src/test/resources and name it accordingly to the xatkit.dialogflow.credentials.path value in your test-variables.properties file.

Note: if you are part of Xatkit you can get in touch with us to get credentials to run your tests.

Clone this wiki locally