Service IV

CI/CD and automated tests for 1C

We set up a pipeline in which every configuration change is built, deployed to a test environment with a fresh copy of production data and checked by automated tests. Manual builds, "weekend" database updates and eyeball checks become a thing of the past.

What we automate

A pipeline from commit to test report

  1. 01

    Build

    Configuration files .cf and extension files .cfe are built from 1C:EDT projects in GitLab CI. The platform and EDT versions are set as parameters.

  2. 02

    Test environment

    Test databases are restored from copies of production ones, the build is applied automatically, and external resources and data exchanges are redirected to test endpoints.

  3. 03

    Automated tests

    Vanessa Automation scenarios run against one or several linked databases. Results are produced in JUnit and Allure, with screenshots of failures.

  4. 04

    Code analysis

    SonarQube with 1C rules checks every merge request and leaves comments directly in it.

  5. 05

    Delivery

    Release branches, versions and build artefacts in GitLab. Database updates are started with a button, not by hand in Designer.

From practice

Automated tests across four databases in 37 minutes instead of an hour

For a 1C partner we reworked the nightly automated test run across four linked databases: ERP, accounting, payroll and a data exchange service.

Full run
over 60 min≈ 37 minPreviously the run did not finish within the allotted hour and was killed by a timeout.
Test database restoration
≈ 14 min6.5 minDatabases are restored in parallel, with memory control on the DBMS server.
Scenario execution
27+ min, aborted10.7 minWe resolved a port conflict between test clients that caused the tests to hang.

1C:SPPR + GitLab

Tests are launched from 1C:SPPR (Application Solution Design System), and results come back there

An analyst describes the scenarios and starts testing a branch in 1C:SPPR. Everything else happens automatically.

  1. 1

    Launch from 1C:SPPR

    A test run document triggers a GitLab pipeline for the required branch.

  2. 2

    Scenario selection

    Scenarios are stored in the project repository and selected according to the test settings.

  3. 3

    Run on a copy of the production database

    The runner restores the test database, applies the build from 1C:EDT and starts Vanessa Automation.

  4. 4

    Statuses in 1C:SPPR

    Results for each scenario are loaded into 1C:SPPR and shown in the branch report.

What's included

  • Assessment of the current development and delivery process
  • GitLab and runners: on your servers or in your cloud
  • Moving configurations to 1C:EDT projects and Git
  • A library of CI templates that plug into a project with a single line
  • Test bench: test databases, DBMS roles, test manager
  • SonarQube with 1C rules and merge request checks
  • Documentation and maintenance guides for the test bench

Tools

  • GitLab CI, shell runners on Linux
  • 1C:EDT, 1cedtcli, ibcmd, rac/ras
  • Vanessa Automation, vanessa-runner, OneScript
  • PostgreSQL for 1C: parallel pg_dump and pg_restore
  • SonarQube with BSL rules
  • 1C:SPPR: launching tests and loading results

Request

Let's discuss a pipeline for your project

Tell us which configurations you have, where your code is stored and how test databases are updated today.

Request

Tell us about your task

We will contact you, clarify the details and suggest where to start.