Commit Graph

33 Commits

Author SHA1 Message Date
Oliver Walters
34a374ce9a Add try/except around callable default 2021-06-27 01:18:09 +10:00
Oliver Walters
0cc999410b More unit test fixes 2021-06-27 01:03:54 +10:00
Oliver Walters
232899e0c4 Simpler implementation 2021-06-27 00:25:23 +10:00
Oliver Walters
ae1a1e139f Further fixes for default API values
- Account for callable defaults
- Extra check in is_valid()
2021-06-27 00:01:40 +10:00
Oliver
ddbf863617 Merge remote-tracking branch 'inventree/master' into api-default-values
# Conflicts:
#	InvenTree/InvenTree/serializers.py
2021-06-26 21:04:41 +10:00
Oliver
5ba7aeaa27 Fixes:
- Use DRF ImageField, not FileField
- Ensure that permissions get updated correctly in 'test' mode
- Allow file upload in the APITester class
2021-06-23 10:28:21 +10:00
Oliver
eae9ff7d1d More unit test fixes 2021-06-22 11:54:18 +10:00
Oliver
9475af62ae Style fixes 2021-06-22 10:12:44 +10:00
Oliver
c62ba5eb12 Perform a "full_clean" on serialized model
- DRF does not by deault run validate_unique on the model
- Need to check if we are "creating" or "updating" a model
- Catch and re-throw errors in the correct format
- Unit tests
2021-06-22 10:09:19 +10:00
Oliver
8fd41f5ecf Unit testing for default values 2021-06-21 21:46:22 +10:00
Matthias
f2b0717d10 removes all lines consisting only of spaces
this really bothers me for some reason - nothing technical
2021-05-06 12:11:38 +02:00
Oliver Walters
4d1eb51bc4 Fixes 2021-04-20 20:42:55 +10:00
Oliver Walters
8a06eaa40d Unit testing 2021-04-11 19:28:39 +10:00
Oliver Walters
9f9629edb3 Fix for unit test 2021-03-01 11:21:18 +11:00
Oliver Walters
90feb6d210 Server-side paginatino for build orders 2021-02-28 20:31:01 +11:00
Oliver Walters
b315b958b0 PEP fixes 2021-02-27 07:56:38 +11:00
Oliver Walters
ee744be5fe Refactor API unit tests for part 2021-02-26 21:45:37 +11:00
Oliver Walters
ae7fbd6112 Add PEP8-naming extension for flake
- Enforcing python naming checks
2020-11-12 21:53:04 +11:00
Oliver Walters
f560be1a9a Bug fix: Part thumbnail API list was not working
- Part images could not be selected from grid
2020-11-04 15:41:17 +11:00
Oliver Walters
b3e4efd96e Unit testing fixes 2020-10-06 16:03:19 +11:00
Oliver Walters
3f59ce3f93 Update unit tests
- requires the user to actually have the necessary permissions!
2020-10-06 01:30:36 +11:00
Oliver Walters
f7ad38dad5 Add unit tests for new aggregation annotation approach 2020-09-05 23:28:54 +10:00
Oliver Walters
95d07cd02b Add unit testing for new API features 2020-05-17 14:14:54 +10:00
Oliver Walters
ea88a03b5a More serial number validation and unit testing
-
2020-05-16 08:43:57 +10:00
Oliver Walters
7503596ea4 More fixes
- Add a set of template tags for rendering status codes
- Improve build API filtering
- Remove some outdated files
- Fix unit testing
2020-04-12 00:10:33 +10:00
Oliver Walters
b25df586cd Fix API tets 2020-04-03 12:30:58 +11:00
Oliver Walters
6e90ac367e Massaging unit tests
- Decimal fields are useful but VERY ANNOYING to use
- Needed to fix some test cases
2019-11-19 08:59:56 +11:00
Oliver Walters
37d9c59a0e Add API endpoint for validating a BOM item 2019-09-05 19:29:51 +10:00
Oliver Walters
ba26acd487 Rename some fields
- Oops didn't think that through, gotta go through and fix the data now...
2019-06-02 19:46:30 +10:00
Oliver Walters
b4df96aaee Simplify extended filters 2019-05-16 19:14:43 +10:00
Oliver Walters
fcc83ca7c7 Part API test suite now uses test data fixtures 2019-05-05 00:15:25 +10:00
Oliver Walters
241f9783ad Added further testing for Part/Bom API 2019-04-27 14:50:49 +10:00
Oliver Walters
f111a42058 Added API tests for Part API
- Uses DRF APITestCase class
2019-04-27 01:03:11 +10:00