RunMat
  • Pricing
RunMat
GitHub
GitHub
Sign inTry in browser
DesktopRuntimePhysicsCADAdministrationAgent

Get RunMat updates

New releases, guides and examples.

Product+
  • Runtime
  • GPU
  • Parallel
  • Compile
  • Interop and MEX
  • Simulation
  • MCAD
  • ECAD
  • Enterprise
  • AI integrations
  • Pricing
  • Download
Math+
  • Signal processing
  • Linear algebra
  • Statistics
  • Curve fitting
  • Differential equations
  • Control systems
  • Optimization
  • Finance
  • Data and tables
  • Plotting
Physics+
  • Simulation overview
  • Structural
  • Thermal
  • Electromagnetic
  • Joule heating
  • Thermal stress
  • Acoustics
  • Fluid flow
  • Conjugate heat transfer
  • Fluid–structure
  • What is FEA
Industries+
  • Aerospace
  • Automotive and transportation
  • Defense
  • Electronics and semiconductors
  • Energy
  • Industrial machinery
  • Life sciences
  • Quantitative finance
Learn+
  • Guides
  • Docs
  • Function reference
  • Language reference
  • Migration guide
  • Changelog
  • MATLAB Online
  • MATLAB AI agent
  • For students
Compare+
  • RunMat vs MATLAB
  • RunMat vs Ansys
  • RunMat vs SOLIDWORKS
  • RunMat vs Altium
  • RunMat vs Cadence
  • RunMat vs COMSOL
  • RunMat vs Python
  • RunMat vs Julia
  • RunMat vs Physics AI
  • RunMat vs Octave
  • Benchmarks
  • MATLAB alternatives
  • All comparisons
Company+
  • About
  • Blog
  • Contact
  • Source code↗
  • License
  • Privacy
  • Terms

Product

  • Runtime
  • GPU
  • Parallel
  • Compile
  • Interop and MEX
  • Simulation
  • MCAD
  • ECAD
  • Enterprise
  • AI integrations
  • Pricing
  • Download

Math

  • Signal processing
  • Linear algebra
  • Statistics
  • Curve fitting
  • Differential equations
  • Control systems
  • Optimization
  • Finance
  • Data and tables
  • Plotting

Physics

  • Simulation overview
  • Structural
  • Thermal
  • Electromagnetic
  • Joule heating
  • Thermal stress
  • Acoustics
  • Fluid flow
  • Conjugate heat transfer
  • Fluid–structure
  • What is FEA

Industries

  • Aerospace
  • Automotive and transportation
  • Defense
  • Electronics and semiconductors
  • Energy
  • Industrial machinery
  • Life sciences
  • Quantitative finance

Learn

  • Guides
  • Docs
  • Function reference
  • Language reference
  • Migration guide
  • Changelog
  • MATLAB Online
  • MATLAB AI agent
  • For students

Compare

  • RunMat vs MATLAB
  • RunMat vs Ansys
  • RunMat vs SOLIDWORKS
  • RunMat vs Altium
  • RunMat vs Cadence
  • RunMat vs COMSOL
  • RunMat vs Python
  • RunMat vs Julia
  • RunMat vs Physics AI
  • RunMat vs Octave
  • Benchmarks
  • MATLAB alternatives
  • All comparisons

Company

  • About
  • Blog
  • Contact
  • Source code↗
  • License
  • Privacy
  • Terms
GitHubXLinkedIn

© Dystr, Inc. · RunMat v0.7.1, Nov 17, 2026 ·

RunMat® is a registered trademark of Dystr, Inc. MATLAB® is a registered trademark of The MathWorks, Inc. RunMat is not affiliated with, endorsed by, or sponsored by The MathWorks, Inc.

/
    • Run tests
    • Change settings
Docs>Desktop>Tests and settings

Run tests

Desktop finds the MATLAB-style tests in a project, runs them and opens a report with each test's result. It uses the same test runner as runmat test on the command line, so a test that passes in Desktop passes in CI with the same inputs.

Set up the project

Desktop looks for tests in the project's source roots. Name them in runmat.toml at the project root:

[package]
name = "weights"

[sources]
roots = ["src", "tests"]

Keep functions in src/ and tests in tests/. Source roots can't overlap, so list sibling folders rather than "." and a folder inside it.

A function-based test file returns its local test functions:

% tests/test_build_weights.m
function tests = test_build_weights
tests = functiontests(localfunctions);
end

function test_nonnegative(testCase)
w = build_weights([1, -2, 3, 4]);
verifyTrue(testCase, all(w >= 0));
end

function test_sums_to_one(testCase)
w = build_weights([1, 2, 3, 4]);
verifyEqual(testCase, sum(w), 1, "AbsTol", 1e-12);
end

Script-based and class-based tests work too. See runmat test.

Run the tests

  1. Open the Run menu with the ⌄ beside the Run button.
  2. Select Run all tests, or Run selected tests… to pick tests from a list.
The Run menu opens with Run on, the file, More files, Run all tests and the before-run switches; Run all tests opens a Test results tab reporting 2 passed and 0 failed.

When the run finishes, a Test results tab opens with the report:

  • the status and how many tests finished, for example Completed · 2 of 2 tests finished;
  • a summary of passed, failed and remaining tests;
  • a row per test with its status and the number of attempts; select a test's name to open it;
  • line coverage of the project's source;
  • the generated report files (text, JSON and JUnit XML), which you can open or attach to a review.

The report is a Markdown file under .artifacts/test-runs/ in the project, so earlier reports stay in the file tree. Settings › Project › Hide internal files hides that folder from the tree.

Fix a failing test

  1. In the report, select the failed test to open it.
  2. Read the failed check and the values it compared.
  3. Fix the function or the test, then run the tests again.

Keep fixtures small and deterministic: seed random inputs and compare floating-point results with a tolerance that suits the calculation, as AbsTol does above.

Match CI

Before you push a change:

  1. Save all files.
  2. Run all tests from the Run menu.
  3. Run the same suite with runmat test in a clean checkout, the way CI will.

When Desktop and CI disagree, compare the RunMat version, operating system, runmat.lock, environment variables and where the tests ran. See Packages in CI.

Packages

Not yet releasedStatus A Packages view in the sidebar lists the project's dependencies from runmat.toml, restores missing versions after you clone or open a project, and adds packages from the RunMat registry or an allowed local source. Until it ships, manage dependencies with the CLI; see Packages.

On this page
  • Set up the project
  • Run the tests
  • Fix a failing test
  • Match CI
  • Packages