mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-11-04 07:05:41 +00:00 
			
		
		
		
	Add fixtures / unit testing for the stock item testing framework
This commit is contained in:
		
							
								
								
									
										39
									
								
								InvenTree/part/fixtures/test_templates.yaml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										39
									
								
								InvenTree/part/fixtures/test_templates.yaml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,39 @@
 | 
			
		||||
# Tests for the top-level "chair" part
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10000
 | 
			
		||||
    test_name: Test strength of chair
 | 
			
		||||
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10000
 | 
			
		||||
    test_name: Apply paint
 | 
			
		||||
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10000
 | 
			
		||||
    test_name: Sew cushion
 | 
			
		||||
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10000
 | 
			
		||||
    test_name: Attach legs
 | 
			
		||||
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10000
 | 
			
		||||
    test_name: Record weight
 | 
			
		||||
    required: false
 | 
			
		||||
 | 
			
		||||
# Add some tests for one of the variants
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10003
 | 
			
		||||
    test_name: Check that chair is green
 | 
			
		||||
    required: true
 | 
			
		||||
 | 
			
		||||
- model: part.parttesttemplate
 | 
			
		||||
  fields:
 | 
			
		||||
    part: 10004
 | 
			
		||||
    test_name: Check that chair is especially green
 | 
			
		||||
    required: False
 | 
			
		||||
		Reference in New Issue
	
	Block a user