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

[WIP] Testable parts #7888

Merged
merged 13 commits into from
Aug 16, 2024
Merged

Conversation

SchrodingersGat
Copy link
Member

@SchrodingersGat SchrodingersGat commented Aug 15, 2024

  • Adds a new field to the part model - testable
  • Separates the concept of testable from trackable
  • Allows stock items to have associated tests, without associated serial numbers (necessarily)
  • Default value for testable is the current value of trackable

TODO

- Default = False
- Determines whether a particular part can have tests defined against it
@SchrodingersGat SchrodingersGat added part Related to Part models user interface User interface api Relates to the API feature Platform UI Related to the React based User Interface labels Aug 15, 2024
@SchrodingersGat SchrodingersGat added this to the 0.17.0 milestone Aug 15, 2024
Copy link

netlify bot commented Aug 15, 2024

Deploy Preview for inventree-web-pui-preview canceled.

Name Link
🔨 Latest commit a48f38f
🔍 Latest deploy log https://app.netlify.com/sites/inventree-web-pui-preview/deploys/66beb635017fe900081d2411

Copy link

codecov bot commented Aug 15, 2024

Codecov Report

Attention: Patch coverage is 91.30435% with 2 lines in your changes missing coverage. Please review.

Project coverage is 83.74%. Comparing base (f14094c) to head (a48f38f).
Report is 5 commits behind head on master.

Files Patch % Lines
...venTree/part/migrations/0129_auto_20240815_0214.py 80.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #7888      +/-   ##
==========================================
+ Coverage   83.35%   83.74%   +0.38%     
==========================================
  Files        1128     1130       +2     
  Lines       50276    50298      +22     
  Branches     1734     1735       +1     
==========================================
+ Hits        41908    42122     +214     
+ Misses       7937     7716     -221     
- Partials      431      460      +29     
Flag Coverage Δ
backend 85.22% <90.47%> (+<0.01%) ⬆️
pui 66.67% <100.00%> (+2.37%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@matmair matmair left a comment

Choose a reason for hiding this comment

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

LGTM; This separation makes a lot of sense

@SchrodingersGat SchrodingersGat merged commit 3880e6f into inventree:master Aug 16, 2024
25 of 26 checks passed
@SchrodingersGat SchrodingersGat deleted the testable-parts branch August 16, 2024 04:54
SchrodingersGat added a commit to SchrodingersGat/InvenTree that referenced this pull request Aug 29, 2024
- limit_choices_to should be "testable", not "trackable"
- ref: inventree#7888
SchrodingersGat added a commit that referenced this pull request Aug 29, 2024
* Fix restriction for PartTestTemplate

- limit_choices_to should be "testable", not "trackable"
- ref: #7888

* Add migration file

* Fix validation check

* Fix API filter

* Fix for test fixture

* Fix another test

* Fixture data

* Fix comment

* More fixes

* More fixes

* Moar fix plz thx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Relates to the API feature part Related to Part models Platform UI Related to the React based User Interface user interface User interface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants