Conversation
Implement a testing harness. This harness is based on checking the results of ffDesign operations against known result shapes to detect when discrepancies appear. As a first step, add tests that check whether we correctly find hole locations on a sketch with both construction geo and non-defining external geo. And a test that generates rib threads for a threaded hole.
Do not show error and warning dialogs during test execution. Dialogs would leave the test hanging because they require user interaction. Instead, skip the dialogs under all circumstances. But to ensure the dialog's intent of notifying of an error is captured in tests, bubble up the exception that would have led to a dialog to the outer scope such that a test will fail because of it.
Instead of calling the ffDesign API, use the RibThreadsTaskPanel to create the rib threads. This is more true to the production code path, but still not quite identical.
Add smoke tests for all rib thread parameters to ensure they successfully generate. The resulting geometry is not checked.
Add a GitHub Actions workflow for running the ffDesign testsuite against AppImages of FreeCAD 1.0.2 and 1.1.1.
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Set up the testing harness and build first tests to check ffDesign against regressions.
See Testing.md for documentation on how the testsuite works.
TL;DR there are test documents in a separate repository (https://github.com/Rahix/ffDesign_TestData) which the tests use to verify the ffDesign commands produce correct output shapes.
Tests are designed to run end-to-end, specifically also covering the GUI parts of ffDesign as far as feasible. Assumptions about the generated feature tree are kept to a minimum - the primary criteria is the resulting output shape.
CI runs for both FreeCAD 1.0 and 1.1 to ensure we don't break backwards compatibility. It uses the official AppImages for least surprising behavior in CI.
This first PR contains a few tests, mainly covering the basics of rib threads, counterbore holes and roof bridges.
Future work should focus on building testcases that specifically exercise corner cases of the ffDesign commands.