Close Menu
    DevStackTipsDevStackTips
    • Home
    • News & Updates
      1. Tech & Work
      2. View All

      Sunshine And March Vibes (2025 Wallpapers Edition)

      May 16, 2025

      The Case For Minimal WordPress Setups: A Contrarian View On Theme Frameworks

      May 16, 2025

      How To Fix Largest Contentful Paint Issues With Subpart Analysis

      May 16, 2025

      How To Prevent WordPress SQL Injection Attacks

      May 16, 2025

      Microsoft has closed its “Experience Center” store in Sydney, Australia — as it ramps up a continued digital growth campaign

      May 16, 2025

      Bing Search APIs to be “decommissioned completely” as Microsoft urges developers to use its Azure agentic AI alternative

      May 16, 2025

      Microsoft might kill the Surface Laptop Studio as production is quietly halted

      May 16, 2025

      Minecraft licensing robbed us of this controversial NFL schedule release video

      May 16, 2025
    • Development
      1. Algorithms & Data Structures
      2. Artificial Intelligence
      3. Back-End Development
      4. Databases
      5. Front-End Development
      6. Libraries & Frameworks
      7. Machine Learning
      8. Security
      9. Software Engineering
      10. Tools & IDEs
      11. Web Design
      12. Web Development
      13. Web Security
      14. Programming Languages
        • PHP
        • JavaScript
      Featured

      The power of generators

      May 16, 2025
      Recent

      The power of generators

      May 16, 2025

      Simplify Factory Associations with Laravel’s UseFactory Attribute

      May 16, 2025

      This Week in Laravel: React Native, PhpStorm Junie, and more

      May 16, 2025
    • Operating Systems
      1. Windows
      2. Linux
      3. macOS
      Featured

      Microsoft has closed its “Experience Center” store in Sydney, Australia — as it ramps up a continued digital growth campaign

      May 16, 2025
      Recent

      Microsoft has closed its “Experience Center” store in Sydney, Australia — as it ramps up a continued digital growth campaign

      May 16, 2025

      Bing Search APIs to be “decommissioned completely” as Microsoft urges developers to use its Azure agentic AI alternative

      May 16, 2025

      Microsoft might kill the Surface Laptop Studio as production is quietly halted

      May 16, 2025
    • Learning Resources
      • Books
      • Cheatsheets
      • Tutorials & Guides
    Home»Development»Unable to run test on gitlab pipeline due to DevToolsActivePort file doesn’t exist

    Unable to run test on gitlab pipeline due to DevToolsActivePort file doesn’t exist

    May 1, 2024

    I created a sample Selenium Webdriver test using java and maven and pushed it out to my gitlab repository. Then I created a new pipeline to run the automated tests. This is my first time running a test on the pipeline so I followed some instructions online. The issue I’m having is that the test fails because of this error: (unknown error: DevToolsActivePort file doesn’t exist)

    I saw some few questions regarding this too and tried to add those solutions but still getting that error. Used this link where I added those arguments.
    WebDriverException: unknown error: DevToolsActivePort file doesn’t exist while trying to initiate Chrome Browser

    Not sure what I need to do to fix this error or how to run the test as a non-root user which can maybe be a workaround.

    This is my yml file for the pipeline

    # calling the docker image where chrome, maven, jdk are available to run the tests
    image: markhobson/maven-chrome:jdk-11

    # building the maven
    build:
    stage: build
    script:
    – mvn compile

    # running the tests
    test:
    stage: test
    script:
    – mvn clean test

    BaseTest class

    @BeforeSuite
    public void beforeSuite() {
    WebDriverManager.chromedriver().setup();
    ChromeOptions options = new ChromeOptions();
    String runTime = null;

    try {
    InputStream input = BaseTest.class.getClassLoader().getResourceAsStream(“runSetup.properties”);
    Properties properties = new Properties();
    properties.load(input);
    runTime = properties.getProperty(“runTimeOnLocal”);
    } catch (IOException e) {
    e.printStackTrace();
    }

    // if it’s true, that means running locally on my machine and open the webrowser
    // if it’s false, that means it’s running on gitlab headless
    if(runTime.equalsIgnoreCase(“TRUE”)) {
    options.addArguments(“start-maximized”);
    options.addArguments(“enable-automation”);
    options.addArguments(“–no-sandbox”);
    options.addArguments(“–disable-infobars”);
    options.addArguments(“–disable-dev-shm-usage”);
    options.addArguments(“–disable-browser-side-navigation”);
    options.addArguments(“–disable-gpu”);
    }
    else if(runTime.equalsIgnoreCase(“FALSE”)) {
    options.addArguments(“–disable-dev-shm-usage”);
    options.addArguments(“–no-sandbox”);
    options.addArguments(“–disable-gpu”);
    options.setHeadless(true);
    }

    driver.set(new ChromeDriver(options));
    Log.info(“Opening web application”);
    driver.get().get(“https://demo.opencart.com/”);
    }

    I also put the link to my repo as this is a sample for me to review selenium (need to switch to master branch)

    SeleniumReview

    Source: Read More

    Facebook Twitter Reddit Email Copy Link
    Previous ArticleMDR: Unlocking the power of enterprise-grade security for businesses of all sizes
    Next Article Understanding Neuro-Symbolic AI: Integrating Symbolic and Neural Approaches

    Related Posts

    Security

    Nmap 7.96 Launches with Lightning-Fast DNS and 612 Scripts

    May 17, 2025
    Common Vulnerabilities and Exposures (CVEs)

    CVE-2024-47893 – VMware GPU Firmware Memory Disclosure

    May 17, 2025
    Leave A Reply Cancel Reply

    Continue Reading

    Design Systems Q&A

    Development

    Forrester shares its top 10 emerging technology trends for 2024

    Development

    New Snake Keylogger Variant Leverages AutoIt Scripting to Evade Detection

    Development

    Live Coding, Hot Topics, and Big Names: Frontend Nation Delivers

    Development

    Highlights

    100+ Computer Keyboard Shortcuts Guide

    July 26, 2024

    Computer keyboard shortcuts are combinations of keys that provide quick and efficient ways to perform tasks on your computer without using the mouse. They save time, help streamline your workflow, and improve productivity. Below is a detailed guide on various types of computer shortcut keys, with each section explained in simple and easy-to-understand language. Must…
    The post 100+ Computer Keyboard Shortcuts Guide appeared first on Software Testing Material.

    Top Object-Oriented Programming Languages for Beginners (OOP Guide)

    May 2, 2024

    ByteDance AI Introduces Doubao-1.5-Pro Language Model with a ‘Deep Thinking’ Mode and Matches GPT 4o and Claude 3.5 Sonnet Benchmarks at 50x Cheaper

    January 26, 2025

    This AI Paper by Alibaba Group Introduces AlphaMath: Automating Mathematical Reasoning with Monte Carlo Tree Search

    May 10, 2024
    © DevStackTips 2025. All rights reserved.
    • Contact
    • Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.