Unit Tests aren't running - PEBKAC?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By tsear

Could someone help me out with running unit tests on Windows, please? I’m following the docs here, but with no success - Unit testing — Godot Engine (latest) documentation in English

  1. I have a locally built Godot executable I made with scons p=windows vsproj=yes
  2. I then compile tests by running scons test=yes
  3. I attempt to execute tests by running ./bin/godot.windows.tools.64.exe --test --test-case="*[String]*" --success, as the documentation suggests
  4. A Godot GUI opens, and no tests are run

I have two other observations, though I don’t know if they’re red herrings.

  1. The docs suggest that I could just build everything with scons dev=yes. But this build fails on a fresh check-out of master.
  2. When I try to execute tests, the console gives me an error - ERROR: Condition "default_certs != nullptr" is true [ at: CryptoMbedTLS::load_default_certificates (modules\mbedtls\crypto_mbedtls.cpp:236]
    " . The GUI opens up just fine though, so it doesn’t look like it has anything to do with the actual test run.
:bust_in_silhouette: Reply From: bruvzg

I then compile tests by running scons test=yes

It’s tests=yes no test

Aha, that did it. Thank you!

tsear | 2020-11-16 14:14

:bust_in_silhouette: Reply From: bruvzg

build everything with scons dev=yes

What compiler/platform are you using?

dev=yes is equivalent to warnings=extra werror=yes, currently master should compile with warnings=extra flag on all compilers except Windows build using MSVC (only works with warnings=all).

Thank you, I am in fact using the visual studio C++ distribution. Is it intended that dev=yes doesn’t work there?

tsear | 2020-11-16 19:49