Continuous Integration
subscribe via RSS
Blog articles | Continuous Integration | Tech tips | News
-
How BitBucket Pipeline with parallel Cypress tests can speed up CI build
Do you use BitBucket Pipeline as your CI server? Are you struggling with slow E2E tests in Cypress? Did you know BitBucket Pipeline can run parallel steps? You can use it to distribute your browser tests across several parallel steps to execute end-to-end Cypress tests in a short amount of time.
-
How to run Ruby on Rails tests on Github Actions using RSpec
Are you thinking about migrating a Ruby on Rails project CI pipeline to Github Actions? You will learn how to configure the Rails app to run RSpec tests using Github Actions.
-
Run Minitest on Github Actions with parallel jobs using build matrix
How to run Ruby on Rails tests in Minitest on Github Actions? What to do if tests are slow? How to manage complex workflows? You can use Github Actions build matrices to divide Minitest files between jobs and run the test suite much faster.
-
How to load Ruby gems from cache on Github Actions
How to start CI build faster by loading Ruby gems from cache on Github Actions? You can start running your tests for a Ruby on Rails project quicker if you manage to set up all dependencies in a short amount of time. Caching can be helpful with that. Ruby gems needed for your project can be cached by Github Actions and thanks to that they can be loaded much faster when you run a new CI build.
-
Faster Cypress + RSpec test suite for Rails apps on GitHub Actions using Knapsack Pro
Cypress is an amazing tool for end to end testing Rails applications, but large test suites can quickly take upwards of 20 minutes to run. That’s where Knapsack Pro comes in. Knapsack Pro Queue Mode to intelligently split your test suite into jobs that can be run in parallel, reducing run time to only a few minutes. In this article we’ll show how to quickly implement Knapsack Pro Queue Mode to speed up both Cypress & RSpec test suites in a Ruby on Rails app on Github Actions
-
Auto-scaling Buildkite CI build agents for RSpec (run parallel jobs in minutes instead of hours)
If your RSpec test suite runs for hours, you could shorten that to just minutes with parallel jobs using Buildkite agents. You will learn how to run parallel tests in optimal CI build time for your Ruby on Rails project. I will also show you a few useful things for Buildkite CI like:
-
Run Jest tests on GitHub Actions with optimal parallelization
Jest is a powerful testing framework used in JavaScript projects. Besides vanilla JS, it’s often used for React, NodeJS, Angular or Vue.js projects, among others. I am going to help you configure running your Jest test suite on GitHub Actions. We are going to use CI parallelization with Knapsack Pro, for maximum effectiveness. Let’s begin.
-
Cucumber BDD testing using Github Actions parallel jobs to run tests quicker
Cucumber employs Behavior-Driven Development (BDD) for testing your application. This type of test is often time-consuming when running in the browser. You will learn how to run Cucumber tests on Github Actions using parallel jobs to execute the test suite much faster.
-
Faster pipelines with Knapsack Pro by parallelizing Cypress tests on GitLab CI
When the runtime of our build pipeline had reached 20 minutes on average for each commit on each Merge Request, we knew we needed a solution to speed things up. We wanted to optimize everything we could within the pipeline, a way of doing this was to parallelize our tests with Knapsack Pro to speed up our Cypress integration tests which would save us a sizable amount of time.
-
Setting up Knapsack Pro in your Ruby RSpec project
Knapsack Pro offers two modes for RSpec tests in your Ruby application: the Regular Mode and the Queue Mode. They differ in their approach towards dividing your test files between parallel CI nodes.
-
RSpec testing parallel jobs with CircleCI and JUnit XML report
You will learn how to run RSpec tests for your Ruby on Rails project on CircleCI with parallel jobs to shorten the running time of your CI build. Moreover, you will learn how to configure JUnit formatter to generate an XML report for your tests to show failing RSpec test examples nicely in CircleCI web UI. Finally, you will see how to automatically detect slow spec files and divide their test examples between parallel jobs to eliminate the bottleneck job that’s taking too much time to run tests.
-
How to build Knapsack Pro API client from scratch in any programming language
You will learn how to integrate with Knapsack Pro API to run parallel tests in any programming language for any testing framework. You will see what’s needed to build from scratch Knapsack Pro API client similar to our existing clients like
knapsack_pro
Ruby gem,@knapsack-pro/jest
for Jest in JavaScript, or@knapsack-pro/cypress
for Cypress test runner (also in JavaScript). -
Fix intermittently failing CI builds due to flaky tests in RSpec
Randomly failing CI builds can be frustrating. One run is green, another is red (with no changes in the code!). Disheartening. Let’s see what can be done with this.
-
How to merge SimpleCov results with parallel Rails specs on Semaphore CI
If you are running Rails specs on parallel machines with Knapsack Pro, one challenge you will run into is combining the code coverage results generated by SimpleCov.
-
How to build native integration with Knapsack Pro API to run tests in parallel for any test runner (testing framework)
Do you know that Knapsack Pro API can work with any test runner in any programming language?
-
How to run slow RSpec files on Github Actions with parallel jobs by doing an auto split of the spec file by test examples
Splitting your CI build jobs between multiple machines running in parallel is a great way to make the process fast, which results in more time for building features. Github Actions allows running parallel jobs easily. In a previous article, we explained how you can use Knapsack Pro to split your RSpec test files efficiently between parallel jobs on GitHub Actions. Today we’d like to show how to address the problem of slow test files negatively impacting the whole build times.
-
How to merge Cypress test reports generated by Mochawesome on Github Actions
Looking through CI logs to find out which of your Cypress tests failed can be time consuming and error-prone, especially when your tests are spread out across several machines. With the Mochawesome test report generator and Github Actions, you can easily generate a beautiful, easy-to-read report of your test run, which merges results from all parallel nodes.
-
How to speed up Ruby and JavaScript tests with CI parallelisation
When working on a larger project, you may struggle with the problem of an increasingly growing set of tests, which over time begins to perform slower on your continuous integration (CI) server. I had this problem while working on a project in Ruby on Rails, where RSpec tests on CircleCI took about 15 minutes.
-
How to run Cypress parallel tests on Codefresh CI server
When you work with end to end tests in Cypress you may notice they quickly get time-consuming for running the whole test suite. The more complex the project the more test cases you may end up with and this can take a long time to run - dozens of minutes or even hours.
-
How to use Codefresh CI parallel steps to run RSpec a few times faster for Rails project
Codefresh.io seems to be a very nice CI solution to work with if you are a Ruby developer. I’ve tested one of my projects on Codefresh to see how it allows running fast tests. Codefresh has a matrix feature that lets you run parallel steps for the CI build. In this article, you will see how to leverage Codefresh matrix configuration and Knapsack Pro client library for testing in parallel your Ruby on Rails project with RSpec test suite.
-
GitHub Actions CI config for Ruby on Rails project with MySQL, Redis, Elasticsearch - how to run parallel tests
You will learn how to configure Ruby on Rails project on GitHub Actions. This specific Rails project has MySQL and Redis database. There is also Elasticsearch service running on CI. If your project is close to that setup below GitHub Actions yaml configuration will allow you to run tests on GitHub CI server.
-
How to run RSpec on GitHub Actions for Ruby on Rails app using parallel jobs
GitHub introduced their own CI server solution called GitHub Actions. You will learn how to set up your Ruby on Rails application on GitHub Actions with YAML config file. To run your RSpec test suite faster you will configure parallel jobs with matrix strategy on GitHub Actions.
-
How to run parallel jobs for RSpec tests on GitLab CI Pipeline and speed up Ruby & JavaScript testing
GitLab CI allows you to run tests much faster thanks to CI parallelisation feature. You can run parallel jobs across multiple GitLab Runners. In order to do it, you will learn how to split tests in a dynamic way across parallel tasks to ensure there is no bottleneck in GitLab Pipeline. Thanks to that CI build can be run as fast as possible so your Ruby & JS tests can be finely fast.
-
Cucumber testing with Jenkins parallel pipeline to get down CI build time
Cucumber is a popular automation testing tool for Behaviour-Driven Development (BDD) but when you use it for some time in your work project then the amount of automated tests adds up and you can spend dozens of minutes to run your Cucumber test suite. Sometimes complex projects can have a few hours of execution time for the Cucumber tests. To save time and speed up your Cucumber builds on CI (Continuous Integration) you can use CI parallelization. In this article, you will see how to do it for Jenkins using Jenkins parallel pipeline.
-
Cypress parallel testing with Jenkins Pipeline stages
In this tutorial for JavaScript end to end testing, you will learn about Cypress test runner for UI automation testing and how to use it with Jenkins CI server. Cypress helps with frontend automation testing using headless browser or just regular browser. E2E tests often take a long time to run and for bigger projects, those type of tests can take dozens of minutes or even hours. To save developers time you want to load balancing Cypress tests across Jenkins parallel pipeline stages. Thanks to that you can run your 1-hour test suite in a few minutes.
-
Split RSpec tests with Jenkins Parallel Pipeline to run specs faster
Jenkins CI server has a declarative pipeline that allows you to set Jenkins parallel stages. You can use the stages to run them at the same time (parallel run) to execute your RSpec test suite in a few smaller faster chunks instead of one long test suite run.
-
How to run tests faster on Heroku CI with parallel dynos
Heroku provides a CI solution out of the box for teams. Heroku CI can run tests in dyno instance for your project. What is more interesting you can run parallel dynos as part of your CI build. This allows you to split tests on parallel dynos to complete CI build faster and save time.
-
Run parallel jobs on Semaphore CI 2.0 to get faster CI build time
Semaphore CI 2.0 allows configuring your CI build task with parallel jobs. This way you can run simultaneously a few different commands that do not depend on each other. But we could also use parallel jobs to split your test suite across a few jobs and this way save time. I will show you how to speed up your CI build for Ruby or JavaScript project (Rails / Node project).
-
Jenkins Pipeline how to run parallel tests in your workflow stages
Jenkins Pipeline is a suite of plugins that allows creating simple-to-complex build stages for your testing environment on CI. We can use Jenkins Pipeline to run a few stages at the same time and thanks to that parallelize test suite across a few stages to complete tests faster.
-
How to run CodeShip Parallel Test Pipelines efficiently - optimal CI parallelization
When you use CodeShip as your CI server you can significantly increase the speed of your CI builds with Parallel Test Pipelines. Pipelines allow you to run multiple commands at the same time, for instance, you can split test suite across a few pipelines and complete the CI build much faster.
-
How to run parallel dynos on Heroku CI to complete tests faster
Heroku provides a CI solution out of the box for teams. They can run tests in dyno instance for your project. What’s more interesting you can run parallel dynos as part of your CI build. This allows you to split tests on parallel dynos to complete CI build faster and save time.
-
How to run Travis CI parallel jobs with build matrix feature fast
Travis CI allows you to run multiple concurrent jobs as part of the same CI build. They even allow for up to 200 parallel jobs for open source projects (the same for private repositories). You can leverage that using Travis build matrix feature to run your project way faster by splitting tests into many smaller jobs that will run a subset of your test suite.
-
Improve CircleCI parallelisation for RSpec, Minitest, Cypress
Maybe you use CircleCI parallelisation to run your test suite across multiple CI nodes but you noticed that some CI nodes take more time to complete tests than the others.
-
Run javascript E2E tests faster with Cypress on parallel CI nodes
Cypress test runner is a great alternative to Selenium in end-to-end testing space. When it comes to E2E tests they tend to grow with time and running them is slow and becomes time wasting or just coffee break for developers. ;)
-
Auto balancing 7 hours tests between 100 parallel jobs on CI - Buildkite example
I like tests. You may like them too because thanks to them you are not afraid to change the code. Tests can help you catch errors earlier. I like tests, even more, when they are fast.