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

[SofaFramework] Create Sofa.Testing module #1834

Merged
merged 19 commits into from Mar 17, 2021

Conversation

fredroy
Copy link
Contributor

@fredroy fredroy commented Feb 18, 2021

[DEMO]

First step for an unified testing system.

This module gathers:

  • helper/testing files: utilitary to write new tests
  • gtest: API Google test (all tests are based on it)
  • SofaGTestMain (force-load SofaSimulationGraph): template of Main to centralize test-related things.

This module needs to be compiled AFTER SofaSimulation, as SofaGTestMain needs SofaSimulationGraph.

Unfortunately, there is still the mess with the plugin SofaTest, which needs to be solved as well.


By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).


Reviewers will merge this pull-request only if

  • it builds with SUCCESS for all platforms on the CI.
  • it does not generate new warnings.
  • it does not generate new unit test failures.
  • it does not generate new scene test failures.
  • it does not break API compatibility.
  • it is more than 1 week old (or has fast-merge label).

@fredroy fredroy added pr: status to review To notify reviewers to review this pull-request pr: experimental Demonstrate an experimental feature NG2: pluginization See https://github.com/sofa-framework/sofa/issues/1527 labels Feb 18, 2021
@fredroy fredroy added this to Doing in SOFA-NG via automation Feb 18, 2021
CMakeLists.txt Outdated
Comment on lines 190 to 194
# add tests of previous projects, now that we have Sofa.Testing enabled
set(SOFAKERNEL_LIST_TARGET_UNITTESTS SofaHelper SofaDefaultType SofaCore SofaSimulationCore SofaSimulationGraph)
foreach(target ${SOFAKERNEL_LIST_TARGET_UNITTESTS})
add_subdirectory(${SOFA_KERNEL_SOURCE_DIR}/modules/${target}/${target}_test)
endforeach()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SofaSimulationGraph_test is missing in tests/CMakeLists.txt though

@hugtalbot hugtalbot added pr: status wip Development in the pull-request is still in progress and removed pr: status to review To notify reviewers to review this pull-request labels Mar 3, 2021
@fredroy fredroy added pr: status to review To notify reviewers to review this pull-request and removed pr: status wip Development in the pull-request is still in progress labels Mar 11, 2021
@fredroy
Copy link
Contributor Author

fredroy commented Mar 11, 2021

[ci-build][force-full-build][with-all-tests]

@fredroy fredroy added NG1: include-graph See https://github.com/sofa-framework/sofa/issues/1527 and removed pr: experimental Demonstrate an experimental feature NG2: pluginization See https://github.com/sofa-framework/sofa/issues/1527 labels Mar 12, 2021
SofaKernel/modules/Sofa.Testing/CMakeLists.txt Outdated Show resolved Hide resolved
Comment on lines -60 to -66

## Tests
# cmake_dependent_option(SOFA_TYPE_BUILD_TESTS "Compile the automatic tests" ON "SOFA_BUILD_TESTS OR NOT DEFINED SOFA_BUILD_TESTS" OFF)
# if(SOFA_TYPE_BUILD_TESTS)
# enable_testing()
# add_subdirectory(${PROJECT_NAME}_test)
# endif()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's remove the whole Sofa.Type_test directory then 👍

Comment on lines +5 to +6
GIT_REPOSITORY https://github.com/fredroy/SofaPython3
GIT_TAG origin/follow_sofa_pr1834
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was planning to create PR once everything compiles (and everything is OK) but why not yes

Comment on lines +5 to +6
GIT_REPOSITORY https://github.com/fredroy/regression
GIT_TAG origin/follow_sofa_pr1834
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can push your changes directly on https://github.com/sofa-framework/Regression and update GIT_TAG only 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok i will push directly the branch in the sofa-framework repo from now on then

@fredroy
Copy link
Contributor Author

fredroy commented Mar 15, 2021

[ci-build]

@fredroy
Copy link
Contributor Author

fredroy commented Mar 16, 2021

[ci-build][force-full-build][with-all-tests]

@hugtalbot hugtalbot added pr: status ready Approved a pull-request, ready to be squashed and removed pr: status to review To notify reviewers to review this pull-request labels Mar 17, 2021
@damienmarchal
Copy link
Contributor

Related to #1827

@epernod epernod merged commit 0323054 into sofa-framework:master Mar 17, 2021
SOFA-NG automation moved this from Doing to Done Mar 17, 2021
@guparan guparan added this to the v21.06 milestone Mar 26, 2021
@fredroy fredroy deleted the create_sofa_testing_one branch October 14, 2021 09:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NG1: include-graph See https://github.com/sofa-framework/sofa/issues/1527 pr: status ready Approved a pull-request, ready to be squashed
Projects
SOFA-NG
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

5 participants