Skip to content

Unittest ftorch_utils Python module#563

Merged
joewallwork merged 96 commits intomainfrom
unittest-pt2ts
Mar 26, 2026
Merged

Unittest ftorch_utils Python module#563
joewallwork merged 96 commits intomainfrom
unittest-pt2ts

Conversation

@joewallwork
Copy link
Copy Markdown
Collaborator

@joewallwork joewallwork commented Mar 12, 2026

This PR provides unit tests for the Python module added in that PR. Some of the functionality from the script is separated out into different modules to make the code more amenable to unit testing.

I propose that the main_cli function doesn't get unit tested. This should be fine so long as all of its components have unit tests because the examples provide integration tests.

@joewallwork joewallwork mentioned this pull request Mar 25, 2026
29 tasks
Co-authored-by: Jack Atkinson <109271713+jatkinson1000@users.noreply.github.com>
Copy link
Copy Markdown
Member

@jatkinson1000 jatkinson1000 left a comment

Choose a reason for hiding this comment

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

Thanks @joewallwork the restructuring is good.

Approving as there's noting major that needs changing as I see it, but there are some suggestions for consideration before you do.

  • Perhaps rename path test/python to test/ftorch_utils to be clear what these tests apply to? Or place tests inside ftorch_utils but I think flat is better here.
  • Rename some tests to make the intent clearer, this might just be to me if you disagree
  • Couple of other small points for you to consider

Comment thread test/python/test_validation.py Outdated
Comment thread test/python/test_validation.py Outdated
Comment thread test/python/test_validation.py Outdated
Comment thread test/python/test_validation.py Outdated
Comment thread test/python/test_validation.py Outdated
Comment thread test/python/test_validation.py Outdated
Comment thread test/python/test_validation.py Outdated
Comment thread ftorch_utils/__init__.py
Comment thread ftorch_utils/pt2ts.py Outdated
cmake --install build

- name: Run Python unit tests
shell: cmd

Check notice

Code scanning / zizmor

usage of GitHub Actions misfeatures Note test

usage of GitHub Actions misfeatures
Base automatically changed from 368_rework-pt2ts to main March 26, 2026 15:15
@joewallwork joewallwork merged commit 1bf8e6b into main Mar 26, 2026
14 checks passed
@joewallwork joewallwork deleted the unittest-pt2ts branch March 26, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

testing Related to FTorch testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants