VisualGDB’s Edition Issues in CI

Sysprogs forums Forums VisualGDB VisualGDB’s Edition Issues in CI

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #36148
    Umair
    Participant

    Hi,

    I’m trying to run unit tests from Continuous Integration pipeline, using “> VisualGDB.exe /runtest …” command. I have installed and configured all the required softwares on the agent server like VisualGDB, Visual Studio as well as toolchain required to build the project.

    I successfully built the project and was able to run the unit tests from cmd using “> VisualGDB.exe /runtest …” command. However, from CI using the same command;

    cd $(System.DefaultWorkingDirectory)/source/${{parameters.sourceDir}}
    $env:VISUALGDB_SHOW_DIAGNOSTIC_OUTPUT=1
    $env:VISUALGDB_VERBOSE_OUTPUT=1
    (get-command VisualGDB.exe).Path
    VisualGDB.exe /runtests ${{parameters.sourceDir}}.vgdbcmake /platform:Hardware /config:${{parameters.buildConf}} /targetPath:$(System.ArtifactsDirectory)\${{parameters.appName}}-Test-$(Build.BuildNumber)\unittest /vsoutput:${{parameters.sourceDir}}-unit-test-report.trx
    

    I’m getting this error;

    2024-11-21T21:23:04.9004367Z ##[section]Starting: Run Unit Tests
    2024-11-21T21:23:04.9027596Z ==============================================================================
    2024-11-21T21:23:04.9027744Z Task : PowerShell
    2024-11-21T21:23:04.9027802Z Description : Run a PowerShell script on Linux, macOS, or Windows
    2024-11-21T21:23:04.9027900Z Version : 2.247.1
    2024-11-21T21:23:04.9027955Z Author : Microsoft Corporation
    2024-11-21T21:23:04.9028023Z Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/powershell
    2024-11-21T21:23:04.9028131Z ==============================================================================
    2024-11-21T21:23:07.2669945Z Generating script.
    2024-11-21T21:23:07.3890346Z ========================== Starting Command Output ===========================
    2024-11-21T21:23:07.4186796Z ##[command]"C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -NoLogo -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command ". 'D:\agent\_work\_temp\7e40db3d-3edb-415f-a643-509b2ccaa8c4.ps1'"
    2024-11-21T21:23:07.8488593Z D:\VisualGDB\VisualGDB.exe
    2024-11-21T21:23:10.1067404Z VisualGDB: routing diagnostic output to console
    2024-11-21T21:23:12.0360628Z Build/launch failed: Your edition of VisualGDB does not support unit tests
    2024-11-21T21:23:12.0361825Z ------------------------------
    2024-11-21T21:23:12.0362966Z Detailed exception info:
    2024-11-21T21:23:12.1278339Z System.Exception: Your edition of VisualGDB does not support unit tests
    2024-11-21T21:23:12.1279002Z at l83.u1(String c, wd2 d, IDELevelProjectInfoForDebugging b, UnitTestTargetInfo a)
    2024-11-21T21:23:12.1279449Z at po.h(String b, m d, IDELevelProjectInfoForDebugging a, UnitTestTargetInfo c)
    2024-11-21T21:23:12.1279871Z at po.f(String[] a)
    2024-11-21T21:23:12.1280123Z ------------------------------
    2024-11-21T21:23:12.1511631Z Product version: 5.6.109.4777
    2024-11-21T21:23:12.1536834Z Press any key...
    2024-11-21T21:23:12.1537246Z
    2024-11-21T21:23:12.2501426Z VisualGDB found an error: VisualGDB version: 5.6.109.4777
    2024-11-21T21:23:12.2501944Z ------------------ System.InvalidOperationException ------------------
    2024-11-21T21:23:12.2502522Z System.InvalidOperationException: Cannot read keys when either application does not have a console or when console input has been redirected from a file. Try Console.Read.
    2024-11-21T21:23:12.2502923Z at System.Console.ReadKey(Boolean intercept)
    2024-11-21T21:23:12.2503170Z at po.d()
    2024-11-21T21:23:12.2503398Z at po.f(String[] a)
    2024-11-21T21:23:12.2503617Z at po.b(String[] a)
    2024-11-21T21:23:12.2503925Z trace=[System.Console.ReadKey:136, po.d:0, po.f:4011, po.b:634]
    2024-11-21T21:23:12.2504130Z
    2024-11-21T21:23:12.8407679Z ##[error]PowerShell exited with code '1'.
    2024-11-21T21:23:12.9141271Z ##[section]Finishing: Run Unit Tests

    I’m currently using VisualGDB’s custom edition. If I’m able to to run unit tests from cmd, why not from CI? Furthermore In CI VisualGDB gives another error;

    System.InvalidOperationException: Cannot read keys when either application does not have a console or when console input has been redirected from a file. Try Console.Read.

    Thanks,

    Umair

    • This topic was modified 3 days ago by Umair.
    #36151
    support
    Keymaster

    Hi,

    It looks like you are trying to use a VisualGDB edition that does not support unit tests:

    2024-11-21T21:23:12.0360628Z Build/launch failed: Your edition of VisualGDB does not support unit tests

    Please make sure you are using the Custom or Ultimate edition.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.