Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[v9] Enable tests #35

Merged
merged 11 commits into from
Oct 3, 2024
Merged

[v9] Enable tests #35

merged 11 commits into from
Oct 3, 2024

Conversation

traversaro
Copy link
Contributor

@traversaro traversaro commented Oct 2, 2024

Given what we learned in conda-forge/gz-sensors-feedstock#51, we can now enable tests also here, these may be helpful to early catch errors like robotology/gz-sim-yarp-plugins#208 .

Checklist

  • Used a personal fork of the feedstock to propose changes
  • Bumped the build number (if the version is unchanged)
  • Reset the build number to 0 (if the version changed)
  • Re-rendered with the latest conda-smithy (Use the phrase @conda-forge-admin, please rerender in a comment in this PR for automated rerendering)
  • Ensured the license file is being packaged.

@traversaro traversaro requested a review from wolfv as a code owner October 2, 2024 15:42
@traversaro
Copy link
Contributor Author

@conda-forge-admin, please rerender

@conda-forge-admin
Copy link
Contributor

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe/meta.yaml) and found it was in an excellent condition.

@traversaro
Copy link
Contributor Author

On Windows are failing:

	 79 - REGRESSION_reload_engine_ogre_gl3plus (Failed)
	 81 - REGRESSION_reload_engine_ogre2_gl3plus (Failed)
	203 - UNIT_RenderingIface_TEST_ogre_gl3plus (Failed)
	205 - UNIT_RenderingIface_TEST_ogre2_gl3plus (Failed)

many more on Linux, but we still need to update the docker image. Almost all tests are also failing with a segfault on osx.

@traversaro
Copy link
Contributor Author

@conda-forge-admin please rerender

@traversaro traversaro changed the title Enable tests [v9] Enable tests Oct 2, 2024
@traversaro
Copy link
Contributor Author

Ok, all ogre_ tests do not pass on Linux as ogre does not support EGL, so it make sense to just keep the ogre2/ogre-next tests on Linux.

@traversaro
Copy link
Contributor Author

Ok, skipping _ogre_ the only failing test on Linux is:

UNIT_RenderingIface_TEST_ogre2_gl3plus 

while almost all the ogre2_metal_ tests fail on macOS.

@traversaro
Copy link
Contributor Author

I reproduce the failure by artificially setting DISPLAY to an empty env variable, to simulate the case in which no X server is available:

(gzrenderingdev) traversaro@IITBMP014LW012:~/gz-rendering/build$ DISPLAY= ctest -E "_ogre_" -R "Iface" -VV
UpdateCTestConfiguration  from :/home/traversaro/gz-rendering/build/DartConfiguration.tcl
Parse Config file:/home/traversaro/gz-rendering/build/DartConfiguration.tcl
UpdateCTestConfiguration  from :/home/traversaro/gz-rendering/build/DartConfiguration.tcl
Parse Config file:/home/traversaro/gz-rendering/build/DartConfiguration.tcl
Test project /home/traversaro/gz-rendering/build
Constructing a list of tests
Done constructing a list of tests
Updating test list for fixtures
Added 0 tests to meet fixture requirements
Checking test dependency graph...
Checking test dependency graph end
test 212
    Start 212: UNIT_RenderingIface_TEST_ogre2_gl3plus

212: Test command: /home/traversaro/gz-rendering/build/bin/UNIT_RenderingIface_TEST "--gtest_output=xml:/home/traversaro/gz-rendering/build/test_results/UNIT_RenderingIface_TEST_ogre2_gl3plus.xml"
212: Working Directory: /home/traversaro/gz-rendering/build/test/common_test
212: Environment variables:
212:  GZ_ENGINE_TO_TEST=ogre2
212:  GZ_ENGINE_BACKEND=gl3plus
212: Test timeout computed to be: 240
212: Running main() from /home/traversaro/gz-rendering/test/gtest_vendor/src/gtest_main.cc
212: [==========] Running 3 tests from 1 test suite.
212: [----------] Global test environment set-up.
212: [----------] 3 tests from RenderingIfaceTest
212: [ RUN      ] RenderingIfaceTest.HasEngine
212: [       OK ] RenderingIfaceTest.HasEngine (0 ms)
212: [ RUN      ] RenderingIfaceTest.GetEngine
212: (2024-10-02 23:15:34.592) [debug] [CommonRenderingTest.hh:44] Read GZ_ENGINE_TO_TEST=ogre2
212: (2024-10-02 23:15:34.592) [debug] [CommonRenderingTest.hh:47] Read GZ_ENGINE_BACKEND=gl3plus
212: (2024-10-02 23:15:34.593) [debug] [RenderingIface.cc:135] No rendering engine is loaded yet
212: envEngine ogre2
212: (2024-10-02 23:15:34.593) [info] [RenderEngineManager.cc:455] Loading plugin [gz-rendering-ogre2]
212: (2024-10-02 23:15:34.615) [warning] [Ogre2RenderEngine.cc:551] Unable to open display: . Trying to run in headless mode.
212: libEGL warning: failed to open /dev/dri/renderD128: Permission denied
212:
212: libEGL warning: failed to open /dev/dri/renderD128: Permission denied
212:
212: libEGL warning: NEEDS EXTENSION: falling back to kms_swrast
212: libEGL warning: failed to open /dev/dri/renderD128: Permission denied
212:
212: libEGL warning: failed to open /dev/dri/renderD128: Permission denied
212:
212: libEGL warning: NEEDS EXTENSION: falling back to kms_swrast
212: eng 0x7fec515934c0
212: (2024-10-02 23:15:35.178) [debug] [RenderingIface.cc:135] No rendering engine is loaded yet
212: (2024-10-02 23:15:35.178) [info] [RenderEngineManager.cc:455] Loading plugin [no_such_engine]
212: (2024-10-02 23:15:35.178) [error] [RenderEngineManager.cc:474] Failed to load plugin [no_such_engine] : couldn't find shared library.
212: (2024-10-02 23:15:35.178) [error] [RenderEngineManager.cc:227] Invalid render-engine index: 1000000
212: [       OK ] RenderingIfaceTest.GetEngine (586 ms)
212: [ RUN      ] RenderingIfaceTest.RegisterEngine
212: (2024-10-02 23:15:35.179) [info] [RenderEngineManager.cc:455] Loading plugin [gz-rendering-ogre]
212: (2024-10-02 23:15:35.195) [error] [OgreRenderEngine.cc:396] Unable to open display:
1/2 Test #212: UNIT_RenderingIface_TEST_ogre2_gl3plus .........***Exception: SegFault  0.64 sec
test 213
    Start 213: check_UNIT_RenderingIface_TEST_ogre2_gl3plus

213: Test command: /usr/bin/python3.12 "/home/traversaro/miniforge3/envs/gzrenderingdev/share/gz/gz-cmake4/tools/check_test_ran.py" "/home/traversaro/gz-rendering/build/test_results/UNIT_RenderingIface_TEST_ogre2_gl3plus.xml"
213: Working Directory: /home/traversaro/gz-rendering/build/test/common_test
213: Test timeout computed to be: 1500
213: Checking for test results in /home/traversaro/gz-rendering/build/test_results/UNIT_RenderingIface_TEST_ogre2_gl3plus.xml
2/2 Test #213: check_UNIT_RenderingIface_TEST_ogre2_gl3plus ...   Passed    0.03 sec

The following tests passed:
        check_UNIT_RenderingIface_TEST_ogre2_gl3plus

50% tests passed, 1 tests failed out of 2

Total Test time (real) =   0.68 sec

The following tests FAILED:
        212 - UNIT_RenderingIface_TEST_ogre2_gl3plus (SEGFAULT)
Errors while running CTest
Output from these tests are in: /home/traversaro/gz-rendering/build/Testing/Temporary/LastTest.log
Use "--rerun-failed --output-on-failure" to re-run the failed cases verbosely.

@traversaro
Copy link
Contributor Author

Ok, skipping _ogre_ the only failing test on Linux is:

UNIT_RenderingIface_TEST_ogre2_gl3plus 

while almost all the ogre2_metal_ tests fail on macOS.

Problem reported upstream in gazebosim/gz-rendering#1072 .

@traversaro traversaro mentioned this pull request Oct 3, 2024
5 tasks
@traversaro
Copy link
Contributor Author

On Windows are failing:

	 79 - REGRESSION_reload_engine_ogre_gl3plus (Failed)
	 81 - REGRESSION_reload_engine_ogre2_gl3plus (Failed)
	203 - UNIT_RenderingIface_TEST_ogre_gl3plus (Failed)
	205 - UNIT_RenderingIface_TEST_ogre2_gl3plus (Failed)

many more on Linux, but we still need to update the docker image. Almost all tests are also failing with a segfault on osx.

Actually all the other tests pass a bit too fast, so I guess they are not actually testing anything.

@traversaro
Copy link
Contributor Author

traversaro commented Oct 3, 2024

For future reference:

conda create -n gzrenderingdev cmake pkg-config make ninja compilers  libgz-math8 libgz-common6 libgz-plugin3 libgz-utils3 ogre-next ogre==1.10.* python

on windows:

conda install dlfcn-win32

on Linux

conda install libgl-devel libopengl-devel libegl-devel libglx-devel

@traversaro
Copy link
Contributor Author

After fixing the test to actually run, the tests that are actually failing on Windows are:

         25 - INTEGRATION_gpu_rays_ogre2_gl3plus (Failed)
         35 - INTEGRATION_mesh_ogre_gl3plus (Failed)
         65 - INTEGRATION_thermal_camera_ogre2_gl3plus (Failed)

@traversaro
Copy link
Contributor Author

After fixing the test to actually run, the tests that are actually failing on Windows are:

         25 - INTEGRATION_gpu_rays_ogre2_gl3plus (Failed)
         35 - INTEGRATION_mesh_ogre_gl3plus (Failed)
         65 - INTEGRATION_thermal_camera_ogre2_gl3plus (Failed)

In CI the tests are much more, let's skip Windows tests there for now.

@traversaro
Copy link
Contributor Author

On osx-arm64, the tests that are not passing locally are:

	 15 - INTEGRATION_camera_ogre_gl3plus (Failed)
	 19 - INTEGRATION_depth_camera_ogre_gl3plus (Failed)
	 29 - INTEGRATION_heightmap_ogre2_metal (Failed)
	 35 - INTEGRATION_mesh_ogre_gl3plus (SEGFAULT)
	159 - UNIT_Material_TEST_ogre_gl3plus (Failed)
	199 - UNIT_RenderEngine_TEST_ogre_gl3plus (Failed)

@traversaro
Copy link
Contributor Author

On osx-arm64, the tests that are not passing locally are:

	 15 - INTEGRATION_camera_ogre_gl3plus (Failed)
	 19 - INTEGRATION_depth_camera_ogre_gl3plus (Failed)
	 29 - INTEGRATION_heightmap_ogre2_metal (Failed)
	 35 - INTEGRATION_mesh_ogre_gl3plus (SEGFAULT)
	159 - UNIT_Material_TEST_ogre_gl3plus (Failed)
	199 - UNIT_RenderEngine_TEST_ogre_gl3plus (Failed)

The only one related to ogre2 is INTEGRATION_heightmap_ogre2_metal, I do not think this explains the failures in robotology/gz-sim-yarp-plugins#208 .

@traversaro
Copy link
Contributor Author

We enabled some tests. macOS and Windows are still disabled, but better then nothing.

@traversaro traversaro merged commit c9d0439 into conda-forge:main Oct 3, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants