How to improve cycle time and estimation

Engineering Metrics

Oct 8, 2023

In the intricate world of software engineering, the efficiency and predictability of project delivery are paramount. As engineering teams strive to meet deadlines and deliver high-quality software, understanding and optimizing metrics like cycle time becomes crucial. This article delves into the significance of reducing cycle time, improving estimation, and how tools like BuildPulse's Impact can be instrumental in this journey.

Deciphering Cycle Time and Its Significance

Cycle time, a pivotal engineering metric, denotes the duration from the initiation of a task to its completion. In software engineering, it often encapsulates the time from when a code change begins until it's deployed. A shorter cycle time signifies an efficient development process, while a prolonged one may indicate potential bottlenecks or inefficiencies.

The Role of Code Review in Cycle Time

Code review is an integral component of the software development process. Efficient code reviews ensure that the code adheres to quality standards and aligns with the objectives of engineering projects. However, challenges like stale pull requests or extended review times can inflate the cycle time.

Stale and long-lived pull requests, in particular, can be detrimental. They not only slow down the development process but also lead to potential merge conflicts, making the code integration process cumbersome. Similarly, stale reviews, where feedback is delayed or overlooked, can hinder the progress of the development teams, leading to extended cycle times.

Strategies to Optimize the Development Process

1. Streamlined Workflows: A clear and well-defined workflow ensures tasks transition smoothly from one stage to the next, reducing downtime and inefficiencies.

2. Automation: Incorporating automation, especially in areas like code testing, can expedite the process, reducing manual intervention.

3. Regular Feedback Loops: Continuous feedback from team members and stakeholders can help identify bottlenecks early, facilitating timely interventions.

4. Skill Development: Ensuring the engineering team is adept with the latest tools and frameworks can reduce task durations and enhance code quality.

Harnessing Metrics for Improved Estimation

Accurate estimation is pivotal for setting realistic expectations and ensuring on-time delivery. Metrics play a central role in this:

1. Benchmarks: Historical data can provide a baseline, aiding in setting realistic goals for future projects.

2. Dashboards: Real-time data on metrics like lead time, lines of code, and pull requests can offer insights, helping engineering leaders make informed decisions.

3. KPIs: Monitoring Key Performance Indicators can help track team performance, ensuring alignment with business goals.

The Power of Tools in Enhancing Cycle Time and Estimation

While understanding and implementing the above strategies is vital, the right tools can amplify these efforts. BuildPulse Engineering Metrics is one such tool that is revolutionizing the way engineering teams approach cycle time. With features like a co-pilot that notifies developers on Slack about estimated PR review times, stale pull requests, and stale reviews, it ensures that the team remains agile.

Such real-time notifications can significantly reduce delays in the review process, ensuring that the cycle time remains optimal. Moreover, with its intuitive dashboards and actionable insights, engineering managers can swiftly identify bottlenecks, allocate resources judiciously, and implement changes to bolster team productivity.


What is the difference between a flaky test and a false positive?

A false positive is a test failure in your test suite due to an actual error in the code being executed, or a mismatch in what the test expects from the code.

A flaky test is when you have conflicting test results for the same code. For example, while running tests if you see that a test fails and passes, but the code hasn’t changed, then it’s a flaky test. There’s many causes of flakiness.

What is an example of a flaky test?

An example can be seen in growing test suites - when pull request builds fail for changes you haven’t made. Put differently, when you see a test pass and fail without any code change. These failed tests are flaky tests.

What are common causes of flakiness?

Broken assumptions in test automation and development process can introduce flaky tests - for example, if test data is shared between different tests whether asynchronous, high concurrency, or sequential, the results of one test can affect another. 

Poorly written test code can also be a factor. Improper polling, race conditions, improper event dependency handling, shared test data, or timeout handling for network requests or page loads. Any of these can lead to flaky test failures and test flakiness.

End-to-end tests that rely on internal API uptime can cause test flakiness and test failures.

What's the impact of flaky tests?

Flaky tests can wreck havoc on the development process - from wasted developer time from test retries, to creating bugs and product instability and missed releases, time-consuming flaky tests can grind your development process to a halt.

What is the best way to resolve or fix flaky tests?

Devops, software engineering, and software development teams will often need to compare code changes, logs, and other context across test environments from before the test instability started, and after - adding retries or reruns can also help with debugging. Test detection and test execution tooling can help automate this process as well. 

BuildPulse enables you to find, assess impact metrics, quarantine, and fix flaky tests.

What are some strategies for preventing flaky tests?

Paying attention and prioritizing flaky tests as they come up can be a good way to prevent them from becoming an issue. This is where a testing culture is important - if a flaky test case is spotted by an engineer, it should be logged right away. This, however, takes a certain level of hygiene - BuildPulse can provide monitoring so flaky tests are caught right away.

What type of tests have flaky tests?

Flaky tests can be seen across the testing process - unit tests, integration tests, end-to-end tests, UI tests, acceptance tests.

What if I don't have that many flaky tests?

Flaky tests can be stealthy - often ignored by engineers and test runs are retried, they build up until they can’t be ignored anymore. These automated tests slow down developer productivity, impact functionality, and reduce confidence in test results and test suites. Better to get ahead while it’s easy and invest in test management.

It’s also important to prevent regressions to catch flakiness early while it’s manageable.

What languages and continuous integration providers does BuildPulse work with?

BuildPulse integrates with all continuous integration providers (including GitHub Actions, BitBucket Pipelines, and more), test frameworks, and workflows.

Combat non-determinism, drive test confidence, and provide the best experience you can to your developers!

How long does implementation/integration with BuildPulse take?

Implementation/integration takes 5 minutes!

Ready for Takeoff?

Ready for Takeoff?

Ready for Takeoff?