CLI test integration is now possible!
Works with any OS
Create, run and edit Functionize tests from the command line
Functionize’s new CLI allows you to create, edit and run our AI tests from the command line. The CLI supports Windows, MacOS and Linux, and you can run tests on any environment, even a local instance. Create CLI test integrations, test local builds and manage all your tests using the command line.
It’s all about the command line
Lots of you have told us you want to use CLI test integration to build Functionize tests right into your toolchain. So over the last few months our engineers have been working hard on this. Today we’re pleased to announce that the Functionize CLI is ready for you to use. Simply download the file, extract it and you’re ready to go!
CLI test integration and more
The Functionize CLI gives you access to a powerful set of commands. It is designed to allow you to easily run Functionize’s AI-powered tests from the command line. With CLI test integration you can integrate tests right into your workflow. But it allows you to do much more. You can run specific tests or whole projects against all browsers or a specified browser. Create new tests using our NLP test generator. Create or delete projects and edit which tests they contain. It also supports our load tests. To see a list of the commands, just launch a terminal/command prompt and type ‘functionize‘.
How it works
Designed for simplicity
The Functionize CLI uses Java so it is OS-agnostic. It has been designed so you simply download, extract and go.
We have designed the Functionize CLI to be as simple as possible to use. To allow it to work cross-OS, we use Java for the actual CLI commands. This is wrapped in either a shell script or a batch file as appropriate. Seamlessly create CLI test integrations whatever your preferred OS! Once you have the CLI folder on your computer you can just run commands as if it was any other shell utility. Because the CLI itself is just a .jar file, updating it is incredibly simple, and can be done automatically from the CLI itself.
Secure from the get-go
Obviously, security matters, and so the Functionize CLI is secured using API keys. When you download the file from our site, it will embed your own API credentials into the zip file. This means as soon as you extract the file you’re good to go with no need to configure anything. All your CLI test integrations will be secure without you needing to worry about it.
Some cool features
Testing against a local server
One of the most powerful features is testing against a locally-running instance of your code. Simply spin up a local server, specify a port and away you go!
Often you will have a new feature you want to test but you don’t want to push it to staging yet. One of the coolest features in our CLI is the ability to test against a local server. Spin up a local instance of your site with the new changes you want. Put it on a suitable port and then tell the CLI to use that port for testing. Simply use the start-tunnel command and the CLI will create a secure tunnel:
functionize start-tunnel 5005
Now, when you run your tests, the Functionize system will run the tests against your local server over this tunnel.
Viewing test output
One of the most popular features in Functionize is the ability to view all the screenshots taken during a test. The Functionize CLI supports this using the view-screenshots command.
When you give this command, the Functionize CLI will launch a browser and take you to a custom URL showing the results of your CLI test. The URL is secure, but it can be shared with other members of your team if they are logged in. This feature is ideal for creating custom CLI test integrations.
We know how frustrating some CLIs can be. That’s why the Functionize CLI includes contextual help. If you pass a command with missing/incorrect parameters you will be shown exactly which parameters it needs. To see an example, try typing the following:
We’re really excited about the potential the Functionize CLI brings. Download it and give it a try! Many people in our team already use it for CLI test integration, and we hope you will too. And remember, we always love to hear from you if you have any improvements or new features to suggest.