At Devicify we are starting to work on an automated testing suite for our own software, but ThWx has nothing built in that I know of. It's definitely not a test first sort of system. I am hoping to find some REST service based testing mechanisms which will ease the pain but that doesn't help with mashups, nor likely security testing. I'm only really commenting here to follow this for future insight from ThWx.
Thank up for replying
Do you have any examples\tutorials? The Java test frameworks are very mature now and patterns exist for mocking, testing and assertions - I think that Thingworx has equivalents yet.
I'm considering using SoapUI for testing and while this should be OK for system, integration and acceptance testing I'm not sure how suited it will be for units tests - I'll update this answer when I have tried.
Matt Ward wrote:
Are you able to use JUnit to test Java Script created inside a Thingworx service?
Could you please let me know on which automation Testing tool you build the Testing Suite to test Thinkworx services?
Let me know some what in detail step by step where and how to build.
1. Can we have your automation Testing suite & test date at our local system?
2. Will your test suite can be used for Regression test execution for Multiple services of IoT?
3. I am Curious to build the similar framework for automating all my services, Could you please share your Test Suite Architecture?
It will be great if you could attach your Test Suite architecture document? Thanks...
1. It's not ready as a component, but could be done with some effort.
2. I don't know if it's exactly what you are searching for, but for each Test Set we have an expected result and it can check if the service returns exactly this result or not ( event if it's an Infotable --> It will check row/column value ). At the previous Screenshot you can see at the bottom right on the left the result and on the right the expected result.
3. What does you mean on sharing our Test Suite Architecture?
We are a small team and for now we don't have it documented. But some features:
- Predefined Test Set List:
- User --> User in whom context execute the Test Set
- checkResult --> If it has to check the result or not
- result ( the expected result if checkResult==true, it supports almost any kind of TW baseTypes, even InfoTables )
- executionMillisMax --> Kind of alarm system in order to detect a service which last longer than previous executions --> This belongs more to Performance Testing for which we had built a totally different suite as requisites for performance testing are different.
- User Impersonation through automatically created AppKeys --> For now it needs Administrator Interaction with the Browser and Incognito mode
- Customer Based Test Set --> Our solution it's a multitenant one, and we may have System Entities and Customer Based Entities which could belong to a totally different tests sets.
- History execution ( to see executioMillis )
- Recurrent execution --> Automatically call Test Sets with a timer in order to detect bugs on the run ( it's not just code that can break result data, maybe malformed data can do it on the run ) --> To implement correctly that could be amazing if TW guys implements an Impersonation feature when the current execution it's done by Administrator.
- Predefined Test Set List: