Streamline test management with the SmartBear QMetry GitLab component

Wait 5 sec.

In modern software development, test management and continuous integration are two sides of the same coin. DevSecOps teams need seamless integration between their CI/CD pipelines and test management platforms to maintain visibility, traceability, and compliance across the software development lifecycle.This becomes even more important as testing scales across automated pipelines, where execution data is spread across tools and harder to track in one place.For organizations using GitLab for CI/CD and SmartBear QMetry for test management, manually uploading test results creates friction, delays feedback loops, and makes it harder to maintain a reliable, centralized view of testing.What if you could automatically publish your JUnit, TestNG, or other test results directly from your GitLab pipeline to QMetry with just a few lines of configuration?That's exactly what the new QMetry GitLab Component enables. This reusable CI/CD component, now available in the GitLab CI/CD Catalog, eliminates the manual overhead of test result management by automatically uploading test execution data to QMetry. This is an AI-enabled, enterprise-grade test management platform that brings together test planning, execution, tracking, and reporting in one place.As a centralized system of record for testing, QMetry helps teams understand coverage, track execution, and make more reliable release decisions.In this guide, you'll learn:How to set up the QMetry GitLab Component in your pipelineHow to configure automated test result uploadsAdvanced configuration options for enterprise requirementsA real-world aerospace industry use caseBest practices for test management automationBy the end of this article, your GitLab pipelines will automatically feed test results into QMetry, giving your QA teams instant visibility into test execution and helping them make faster, more confident release decisions.Why integrate GitLab with QMetry?Before diving into the technical implementation, let's understand the value this integration delivers:Eliminate manual test result uploadsDevSecOps engineers and QA teams no longer need to manually export test results from CI/CD runs and import them into test management systems. The component handles this automatically after every pipeline execution.This reduces manual effort while ensuring test data stays consistent, up to date, and easy to access across teams.Enable end-to-end traceabilityBy connecting GitLab's CI/CD execution data with QMetry's test management capabilities, teams gain complete traceability from requirements through test cases to actual test execution results. This is critical for regulated industries like financial services, aerospace, medical devices, and automotive, where audit trails are mandatory and regulatory compliance depends on demonstrating complete test coverage.It also gives teams a clearer view of coverage and risk across releases, making it easier to understand what’s been tested and what still needs attention.Accelerate feedback loopsAutomated test result uploads mean QA teams, product managers, and stakeholders see test execution results immediately after pipeline completion – no waiting for manual data entry or report generation.With faster access to results, teams can act immediately, reduce delays, and make quicker, more informed release decisions.Support compliance and audit requirementsFor organizations in regulated industries, maintaining comprehensive test records with proper versioning and traceability is non-negotiable. This integration ensures you can document every test execution properly in QMetry with links back to the specific GitLab pipeline, commit, and build.This creates an audit-ready record of testing activity without adding manual overhead.Leverage AI-powered test insightsQMetry uses AI to analyze test execution patterns, identify flaky tests, predict test failures, and recommend optimization opportunities. Feeding it real-time data from GitLab pipelines maximizes the value of these AI capabilities.With continuous data flowing in, teams get more accurate insights and can focus their efforts where it matters most.About the GitLab and SmartBear partnershipThis component represents a growing partnership between GitLab and SmartBear to better connect CI/CD execution with test management in a single workflow. SmartBear brings deep expertise in testing, API management, and quality automation, while GitLab provides the most comprehensive AI-powered DevSecOps platform. Together, they help teams streamline how testing fits into the development lifecycle while maintaining the quality, security, and compliance standards their industries require.Whether you're managing test execution for aerospace flight control systems, financial services platforms, automotive safety applications, or medical device software, the combination of GitLab's CI/CD capabilities and QMetry's test management gives teams a centralized, reliable view of testing across the lifecycle, helping them track execution, maintain traceability, and make more confident release decisions.What you'll needBefore getting started, ensure you have:A GitLab account with a project containing automated tests that generate test result files (JUnit XML, TestNG XML, etc.)QMetry Test Management Enterprise account with API access enabledQMetry API Key generated from your QMetry instance (we'll cover this shortly)QMetry Project already created where you will upload test resultsFamiliarity with GitLab CI/CD, including understanding of basic .gitlab-ci.yml syntax and pipeline conceptsTest suite configuration in QMetry (optional but recommended for better organization)Understanding the test result flowHere's what happens when you integrate this component:Test execution: Your GitLab CI/CD pipeline runs automated tests (unit tests, integration tests, E2E tests, etc.).Result generation: Tests produce output files in formats like JUnit XML, TestNG XML, or other supported formats.Component invocation: The QMetry component executes as a job in your pipeline.Automatic upload: The component reads your test result files and uploads them to QMetry via API.QMetry processing: QMetry receives the results, processes them, and makes them available for reporting and analysis.The beauty of this integration is that it happens automatically, with no manual intervention required once configured.Part 1: Getting your QMetry API credentialsBefore configuring the GitLab component, you need to obtain API access credentials from your QMetry instance. Here are the steps to follow:1. Access QMetry settingsLog in to your QMetry Test Management Enterprise instance.Navigate to your user profile (typically in the top-right corner).Select Settings or API Access from the dropdown menu.2. Generate an API keyIn the API Access section, click Generate New API Key.Provide a descriptive name for the key (e.g., "GitLab CI/CD Integration").Set appropriate permissions. The key needs write access to upload test results.Click Generate.Copy the API key immediately as it will only be displayed once.Important security note: Treat your API key like a password. Never commit it directly to your .gitlab-ci.yml file or store it in plain text. We'll use GitLab CI/CD variables to store it securely.3. Note your QMetry instance URLYou'll also need your QMetry instance URL, which typically follows this format:https://your-company.qmetry.comor, for self-hosted instances:https://qmetry.your-company.comMake note of this URL because you'll need it in the next section.Part 2: Configuring GitLab CI/CD variablesNow that you have your QMetry credentials, let's store them securely in GitLab. Here are the next steps to follow:4. Navigate to CI/CD settingsOpen your GitLab project.In the left sidebar, navigate to Settings > CI/CD.Expand the Variables section.Click Add variable.5. Add the QMetry API keyConfigure the API key variable:FieldValueKeyQMETRY_API_KEYValueYour QMetry API key from Step 2TypeVariableFlags✅ Mask variable✅ Protect variable (recommended)Click Add variable to save.6. Add the QMetry instance URLAdd a second variable for your instance URL:FieldValueKeyINSTANCE_URLValueYour QMetry instance URL (e.g., https://your-company.qmetry.com)TypeVariableFlags(optional: Protect variable)Click Add variable to save.Why use CI/CD variables?Security: Masked variables are hidden in job logs.Reusability: You can use the same credentials across multiple pipelines.Flexibility: It is easy to rotate credentials without modifying pipeline code.Access control: Protected variables are only available on protected branches.Part 3: Understanding your test result filesBefore integrating the component, ensure your tests generate output files that QMetry can process. Here are the next steps to follow:7. Verify test output formatThe QMetry component supports multiple test result formats. The most common is JUnit XML, which most testing frameworks can generate:Example JUnit XML output (results.xml):