A Provnego project for demonstrating the basics of Selenium-based actuation. This project searches for "pizza", "strawberry", or "banana" in the Ecosia search engine, and validates that pages containing these terms were indeed found.
❗
|
This demo project does not look into any other features of the Provengo system, such as DSLs, multi-level event flows, optimized test suite generation, etc. Just Selenium actuation and some Provengo extensions to JavaScript. |
❗
|
Provengo is not publicly accessible yet. If you find this repo interesting and wand to join our closed beta, please contact hello@provengo.tech. |
🔥
|
For the autoamtion sections below to work, you must have a running Selenium server (grid), Chrome, and a chrome selenium driver. Selenium Server can be installed from here. For the Chrome driver, see the "Browsers" section. You’ll have to scroll down quite a bit. |
-
SimpleSearch.js A script for testing a web search engine.
-
provengo.yml Configuration file.
💠
|
In the below listings, we assume that provengo.bat is in the path, and that selenium-basics is the path to this directory (i.e. run this code from the directory that directly contains selenium-basics ). For UNIX systems, change provengo.bat to provengo.sh .
|
Perform a single run through the specification, with no actuations. Good for "Sanity checks", e.g. to see examples of what can happen. Does not require any Selenium server.
provengo.bat run --dry-run selenium-basics
Perform a single run through the specification. Selenium server needs to be running for this.
provengo.bat run selenium-basics
Running with the browser visible
provengo.bat run --show-sessions selenium-basics
Running with delayed actions. Units are milliseconds, so the 5000
in the below snippet means "5 seconds".
provengo.bat run --action-delay 5000 selenium-basics
The above flags can of course be used together.
💠
|
This requires Graphviz to be installed. |
Draw the specification in a PDF file.
provengo.bat analyze -f pdf selenium-basics
Sample 10 scenarios into a file. The scenarios are stored in a file called samples.json
(this can be changed using the -o
/--output-file
switch).
provengo.bat sample --delete-previous --sample-size 10 selenium-basics
Run the sampled tests as a single test suite.
provengo.bat run --run-source samples.json selenium-basics
-
This is a very basic sample project that does not cover all system features. For example, we left suite optimizations and DSLs out.
-
To gain more visibility into what
provengo
is doing, invoke it with the--verbose
flag betweenprovengo
and the verb, like so:
provengo.bat --verbose run selenium-sample
-
To display command options, type
provengo.bat
in the console. To display the reference for a specific command, add-h
after it, like so:provengo.bar run -h
.