How to set up unit testing for a simple solution

Dear Servoy community,

I would like to test my Servoy-solution, then I do the following steps

  1. Create a soltuion, let’s call my_solution_test
  2. In the scopes, I defined a new scope call, test_Service
  3. In the test_Service scope, I simply implemented the following logic
function should_return_true() {
    jsunit.assertTrue(true);
}
  1. Execute the test by right-click on the solution, then choose the option: Run JS Unit Test(s)

I got the following error:

AssertionFailedError: The selection does not have jsunit tests. (JsUnit.js#691)

Could you please help me out?

Thanks

Your method name needs to start with “test_”. Have a look at this to help you get started:

https://wiki.servoy.com/display/Serv7/Unit+Testing

Thanks for your quick help!