2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-05 21:20:56 +00:00

Update test fixtures

- Can't assume that pk values will be assigned sensibly!
- Need to hard-code them in
This commit is contained in:
Oliver Walters
2020-09-02 19:47:07 +10:00
parent bc2f131144
commit 911727f7b7
15 changed files with 85 additions and 57 deletions

View File

@ -2,6 +2,7 @@
# 10 x M2x4 LPHS
- model: part.bomitem
pk: 1
fields:
part: 100
sub_part: 1
@ -9,6 +10,7 @@
# 40 x R_2K2_0805
- model: part.bomitem
pk: 2
fields:
part: 100
sub_part: 3
@ -16,6 +18,7 @@
# 25 x C_22N_0805
- model: part.bomitem
pk: 3
fields:
part: 100
sub_part: 5
@ -23,6 +26,7 @@
# 3 x Orphan
- model: part.bomitem
pk: 4
fields:
part: 100
sub_part: 50

View File

@ -20,12 +20,14 @@
# And some parameters (requires part.yaml)
- model: part.PartParameter
pk: 1
fields:
part: 1
template: 1
data: 4
- model: part.PartParameter
pk: 2
fields:
part: 2
template: 1

View File

@ -38,6 +38,7 @@
- model: part.part
pk: 4
fields:
name: 'R_4K7_0603'
description: '4.7kOhm resistor in 0603 package'
@ -50,6 +51,7 @@
# Create some capacitors
- model: part.part
pk: 5
fields:
name: 'C_22N_0805'
description: '22nF capacitor in 0805 package'

View File

@ -1,25 +1,30 @@
# Tests for the top-level "chair" part
- model: part.parttesttemplate
pk: 1
fields:
part: 10000
test_name: Test strength of chair
- model: part.parttesttemplate
pk: 2
fields:
part: 10000
test_name: Apply paint
- model: part.parttesttemplate
pk: 3
fields:
part: 10000
test_name: Sew cushion
- model: part.parttesttemplate
pk: 4
fields:
part: 10000
test_name: Attach legs
- model: part.parttesttemplate
pk: 5
fields:
part: 10000
test_name: Record weight
@ -27,12 +32,14 @@
# Add some tests for one of the variants
- model: part.parttesttemplate
pk: 6
fields:
part: 10003
test_name: Check that chair is green
required: true
- model: part.parttesttemplate
pk: 7
fields:
part: 10004
test_name: Check that chair is especially green