community postAL Developmentcommunity - not Microsoftreviewed - checked by Opus

Business Central 2026 release wave 1 (BC28): Run AL tests from Visual Studio Code (Test codeunits and test methods)

Business Central 2026 wave 1 adds the ability to discover and run AL tests directly inside Visual Studio Code without switching to external tools. Developers can now use Test Explorer to automatically detect test codeunits and test methods, run tests with different profiles, and view coverage results, reducing context-switching and supporting test-driven development.

post Dynamics 365 Lab

Yun Zhu · 2026-04-09 · 675 words · about 3 min

"This tighter integration with the IDE reduces context-switching, shortens feedback loops, and makes it easier to adopt test-driven development practices."

Key points

  • Test Explorer in Visual Studio Code automatically discovers test codeunits and test methods in the active workspace
  • Multiple run profiles available: Publish & Run (default), Run, Run & Debug, and Coverage (Procedure)
  • Running tests from VS Code is supported in sandbox and on-premises environments but not production
  • AI tests and test runner-dependent events are not supported when running from VS Code; isolation level defaults to Codeunit level unless specified

Quotes

  • “This tighter integration with the IDE reduces context-switching, shortens feedback loops, and makes it easier to adopt test-driven development practices.” (Explains the key business value of bringing testing capabilities directly into the development environment)

Heads up

  • warning: “Running AI tests isn’t supported.” (about version 28)
  • gotcha: “Tests that rely on events published by a test runner for setup or teardown might not work.” (about version 28)
  • warning: “Running tests on production environments isn’t supported, as it might affect business operations.” (about version 28)

Context

  • Features: Test Explorer in Visual Studio Code, Automatic test discovery, Run AL tests without republishing, Run with debugger attached, Code coverage collection, GitHub Copilot integration for test setup
  • Versions: 2026 wave 1, BC28

Source: Dynamics 365 Lab - Yun Zhu, community blog. Summary, key points and quotes are derived (CONTENT-NOTICE.md); read the original for the full text.