ROBOTMK

ROBOT FRAMEWORK /
checkMK
integration

Integrate the Results of Robot Framework Tests into the Monitoring System checkMK

RobotMK ensures that the results of Robot Framework End2End-Tests can be integrated into the monitoring system CheckMK. Robot fully automatically tests websites and applications and allows the use of over 40 libraries, inter alia for

  • Selenium
  • SikuliX
  • AutoIT
  • SAP
  • and many more. 

RobotMK is currently under development is published shortly under the GPLv3.

You can receive news about the development of 
RobotMK, new features and tutorials concerning all aspects of the topic CheckMK and Robot by subscribing the newsletter:

What is RobotMK?

RobotMK contains the names of the two tools Robot Framework and CheckMK (for further details see below).


With Robot Framework you can automatically test programs, web sites (and much more...) from the perspective of the user (so called End2End-Tests, also named "End User-Experience").
Software developers appreciate this type of tests, as an application can thus for instance be tested swiftly in all its facets and variations before being released in a new version.

It is a great advantage to also have such tests in the monitoring system CheckMK and be able to check continuously...

  • ...whether the login into the CRM system functions – and how long it takes
  • ....whether the search function in the SAP/merchandise management system for randomly selected article numbers works
  • ...how efficiently the ordering process functions in the web shop
  • ...etc...

So far this possibility has not existed. Now RobotMK creates a bridge and permits the integration of the results of Robot-tests into the monitoring system CheckMK.

RobotMK connects:

Open-Source Test Framework

Robot Framework

Robot Framework is a generic framework for carrying out automated software tests. It was developed in 2005 by NSN (the former Nokia Siemens Networks) within a master thesis and was published in 2008 under the Apache licence as Open Source. The special feature of Robot is its expandability via Python libraries. Anybody who still has not found something suitable amongst the over 40 existing libraries for Selenium, SikuliX, AutoIT, SAP etc. can expand Robot with his own code as needed. 

Open-Source Monitoring Solution

CheckMK

CheckMK started in the year 2008 as a simple "add-on" for the monitoring system Nagios, but in the meantime has evolved into an independent, extensive monitoring solution. With nearly 2000 checks on board, CheckMK covers a large spectrum of hardware and software which are to be monitored. CheckMK backing tribe29 GmbH from Munich offers the monitoring system as an Enterprise Edition (CEE) on the one hand, but also as a freely usable Open Source version (CRE = Raw Edition).

Features of RobotMK

Recording of runtime metrics in performance graphs

Which elements of a Robot test (suites, tests, keywords) are to be recorded in CheckMK-graphs, can be determined via a sophisticated, pattern-based rule system. After all, the whole is expected to remain clearly structured.
Here the advantages of the rule inheritance in CheckMK`s WATO (web administration tool) come into effect: global rules ensure metrics which always are to be recorded; rules based on host or suite are relevant for the detailed configuration. Don't repeat yourself.

Alarms about runtime changes

In RobotMK the runtimes of all test elements are available for evaluation. 

Here too, pattern based WATO rules allow to set runtime thresholds of Robot suites, tests and keywords globally as well as on a per-suite basis.

Alarms about functional disruptions

If your customer notices that some images are not displayed in your web shop, it is actually too late. 

Robot Framwork is the "automated user": it continuously checks the GUIs of SAP, CRM, Intranet, Website etc. for its usability.  

Robot-Tests can be parametrized dynamically with the DataDriver library using data sources like CSV, XLS/XLSX, MS PICT etc. to achieve test coverage at its best. 

Reporting

How was the availability of all core applications

Meaningful reports can be generated from the data RobotMK delivers to CheckMK. 

They can also be used to review the quality and fulfilment of SLAs for external interfaces. 


Showroom

Live demo: Robot-Test "Log into CheckMK user portal with wrong credentials"

You also should check what should not happen!

This Robot test ensures that the CheckMK user portal  only accepts valid login data and thus expects a proper error massage after entering a series of wrong credentials.

You can see Robot using the state-of-the-art Selenium Library (https://www.selenium.dev/), the test runs browser independent in Firefox, Chrome, Edge, etc... 

Code-Insight "invalid_logins.robot"

This screenshot shows the Robot file which runs the test above. 

To be emphasized: 

  • the "Template" mechanism of Robot: for each test case, the special keyword "Login With Invalid Credentials Should Fail" gets executed with parameters (= wrong login credentials). 
  • All generic/re-usable keywords and variables are stored in a Resource file. This can also be Python-Scripts, which generate test data on the fly (e.g. from a database, Excel sheets etc.)
  • Nesting keywords allows to abstract complex things. Using the output_depth rule in WATO you only see what you are interested in. 

Live demo: collecting metrics in CheckMK

New tests are transferred to CheckMK without any intervention and notified by the check "Check_MK Discovery" (yellow). The following Inventory integrates the Robot test into the monitoring system. 


Live demo: enabling alarms & performance data

WATO rules define the conditions for alarms you want to get for runtime transgressions of certain suites, keywords and tests. It is not necessary to define "steps" by hand (as in the test framework Sakuli), because each keyword is a "step" on its own.  

Rules also define which performance data should be generated. 

History

My former employer Consol in Munich decided in 2018 to submit the E2E Test Framework Sakuli (a combination of SikuliX and Sahi), which had been co-founded by me in 2014, to a complete rewrite and to offer it from now on as a Freemium product (Sakuli v2).

Looking for an alternative to the commercial version of Sakuli v2, I came across the Robot Framework in November 2019. Surprisingly – after all, CheckMK and Robot did not appear on the market only yesterday – no interface between the two tools could be found. It seemed as if Robot had been perceived so far mainly as a tool for QA respectively CI/CD testing, but not for the continuous monitoring of applications. I started programming RobotMK to fill this gap.

In January 2020 I had the opportunity of presenting my prototype of RobotMK at the “Robocon” in Helsinki to a professional audience. The good feedback to this talk (and also the evident interest in CheckMK) gave me the necessary push to continue working on the project.

Robocon 1/2020, Helsinki: "Robot Framework meets CheckMK"

Presentation of the RobotMK prototype, Simon Meggle


The Advantages of Robot Framework/RobotMK

Central control via WATO

RobotMK is configured via a powerful rule system in the web administration interface of CheckMK (WATO).

Flexible evaluation

RobotMK also evaluates intricately interleaved Robot results; the pattern-based reduction of the output to the essential ensures an optimum result. 

Robot speaks

Robot keywords can be encapsulated at will to modularize internal processes – with free name choice. The result: traceable results and messages in the monitoring system.

100% compatible

RobotMK does not require any adaptation to existing Robot tests; they can be integrated in CheckMK without any intervention.

Performance monitoring

RobotMK monitors the runtimes of whole suites, tests and keywords assisted by the pattern-based rule system. Even insidious performance changes can thus be detected.

Worthwhile addition to CheckMK

Robot tests are the perfect addition for a detailed CheckMK monitoring. An eye is thus kept on the bigger picture.

Many established tools in one

Robot Framework is the Suisse pocket knife for many established test methods (web, image pattern, protocol...) and allow their combined use in a test.

Strong community

Great if you have backed the right horse, in case help is required: CheckMK and Robot have a worldwide, English speaking community at their disposal. 

Platform-independent

One for all: Robot Framework works on all common platforms: Windows, Linux, MacOS, Android, iOS, ... including the appropriate test libraries in each case (e.g. Auto-IT for Windows automation).

100% Open Source

RobotMK - like Robot Framework and CheckMK Raw – is published as an Open Source project. No hidden costs, no vendor-lock-in.

When I had discovered Robot Framework, it was clear to me that an integration for CheckMK had to be programmed.

No other test framework can be expanded so flexibly with libraries as Robot: all leading testing tools such as Auto-IT, Selenium, SikuliX etc. are already represented with a library.

In the case of Robot one does not „code“, one „writes“. The keyword driven approach meets equally the requirements of developers and test users. 

Simon Meggle (Author)

FAQ

What do I need to start?

First, you need a translation for the german version, Simon.

Download RobotMK

RobotMK is published under the GPLv3 licence since July, 1st 2020.

Package

RobotMK - checkmk Exchange

RobotMK can be downloaded and installed as MKP (checkmk package) by clicking on checkmk->WATO->Extension Packages into any existing checkmk site (v1.6, CEE/CRE).

Source Code

RobotMK - GitHub

Link to the repository, issue tracker and project board. 

The site also gives some valuable information about planned milestones.  

Free initial assessment

So you want to round up your IT Monitoring with Robot Framework E2E tests?

You want to have a first assessment "from the bird's eye view" about the next steps?

Then sign up for a free first call

Sponsoring

RobotMK is Open-Source and non-commercial. A big part of the current work so far was done in advance. Sponsoring the project will help to implement new features and make RobotMK still better.

Advantages of sponsoring:

Prioritized treatment of feature requests

Listing as sponsoring partner

Be a trailblazer for a cool project

>