mirror of
				https://github.com/graphql-python/graphene.git
				synced 2025-11-04 09:57:41 +03:00 
			
		
		
		
	Fixed mutation tests
This commit is contained in:
		
							parent
							
								
									b4657a5796
								
							
						
					
					
						commit
						92dbba91b7
					
				| 
						 | 
					@ -1,7 +1,7 @@
 | 
				
			||||||
import pytest
 | 
					import pytest
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from ...types import (Argument, Field, InputField, InputObjectType, ObjectType,
 | 
					from ...types import (Argument, Field, InputField, InputObjectType, ObjectType,
 | 
				
			||||||
                      Schema, AbstractType)
 | 
					                      Schema, AbstractType, NonNull)
 | 
				
			||||||
from ...types.scalars import String
 | 
					from ...types.scalars import String
 | 
				
			||||||
from ..mutation import ClientIDMutation
 | 
					from ..mutation import ClientIDMutation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -64,7 +64,8 @@ def test_mutation():
 | 
				
			||||||
    assert field.type == SaySomething
 | 
					    assert field.type == SaySomething
 | 
				
			||||||
    assert list(field.args.keys()) == ['input']
 | 
					    assert list(field.args.keys()) == ['input']
 | 
				
			||||||
    assert isinstance(field.args['input'], Argument)
 | 
					    assert isinstance(field.args['input'], Argument)
 | 
				
			||||||
    assert field.args['input'].type == SaySomething.Input
 | 
					    assert isinstance(field.args['input'].type, NonNull)
 | 
				
			||||||
 | 
					    assert field.args['input'].type.of_type == SaySomething.Input
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
def test_mutation_input():
 | 
					def test_mutation_input():
 | 
				
			||||||
| 
						 | 
					@ -86,7 +87,8 @@ def test_subclassed_mutation():
 | 
				
			||||||
    assert field.type == OtherMutation
 | 
					    assert field.type == OtherMutation
 | 
				
			||||||
    assert list(field.args.keys()) == ['input']
 | 
					    assert list(field.args.keys()) == ['input']
 | 
				
			||||||
    assert isinstance(field.args['input'], Argument)
 | 
					    assert isinstance(field.args['input'], Argument)
 | 
				
			||||||
    assert field.args['input'].type == OtherMutation.Input
 | 
					    assert isinstance(field.args['input'].type, NonNull)
 | 
				
			||||||
 | 
					    assert field.args['input'].type.of_type == OtherMutation.Input
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
def test_subclassed_mutation_input():
 | 
					def test_subclassed_mutation_input():
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user