Large Scale 3D Printing - Cosine

View Original

Software Testing Environment

To help catch errors earlier and prevent them from making it to the user, we proposed the creation of a testing environment at Cosine’s facility in Houston. The idea behind it being that any time we make a change to our software, we run a suite of tests and the software is not released to the user unless all of those tests pass.

 

We use a software called Jenkins in order to create this testing environment. Jenkins is what is known as an automation sever. Cosine has been using Jenkins for quite some time as a build server to compile our software and produce installable files. Now we are using it as a testing environment as well. Another technology that Cosine has already been using but was very instrumental in allowing us to develop this testing environment is Virtual Machines. A Virtual Machine is a digital representation of a physical computer and we use them in many different ways, but we were able to utilize them in the testing environment by creating a virtual machine for every physical printer we have. Then on each virtual machine we have what is called a Simulator. This is a piece of technology that is part of the Motion Control system that allows us to have a simulation of a physical printer, so we can do things like start a print and it will load the print like normal and the “axes” will move without anything happening physically.

 

The workflow of the testing environment is that someone commits their code to our version control system (SVN), and then that code is built on Jenkins. If the code builds correctly then it is used in what is called a Pipeline on Jenkins . A pipeline consists of a series of stages that the software has to pass before it can be released to a customer. If the software fails a stage then we determine why it failed and fix it, and then iterate upon this process until it passes all of the stages. Building the executable, installing it on a virtual machine, and running a print on a virtual machine are all examples of different stages of a pipeline. In the future we will also have a test to run the software on a physical printer as well.


The creation of this testing environment has greatly reduced the number of bugs that have been able to reach customers which in turn has saved both Cosine and it’s users countless hours of time figuring out and fixing bugs. As with any software project there are still bugs that make it through, but as we find new bugs we create more tests and there are fewer and fewer bugs that find their way to the end user.