use of com.generated.graphql.Droid in project graphql-maven-plugin-project by graphql-java-generator.
the class AbstractIT method test_droidPartial.
@Test
void test_droidPartial() throws GraphQLRequestExecutionException, GraphQLRequestPreparationException {
// queryType.droid("{id appearsIn primaryFunction name}", "3");
Droid d = queries.droidPartial("00000000-0000-0000-0000-000000000003");
checkCharacter(d, "droidSimple", null, "C-3PO", 0, Episode.EMPIRE);
assertEquals("Function of C-3PO", d.getPrimaryFunction());
}
use of com.generated.graphql.Droid in project graphql-maven-plugin-project by graphql-java-generator.
the class AbstractIT method test_droidFull.
@Test
void test_droidFull() throws GraphQLRequestExecutionException, GraphQLRequestPreparationException {
// queryType.droid("{id appearsIn primaryFunction name}", "3");
Droid d = queries.droidFull("00000000-0000-0000-0000-000000000003");
checkCharacter(d, "droidSimple", "00000000-0000-0000-0000-000000000003", "C-3PO", 0, Episode.EMPIRE);
assertEquals("Function of C-3PO", d.getPrimaryFunction());
}
use of com.generated.graphql.Droid in project graphql-maven-plugin-project by graphql-java-generator.
the class AbstractIT method test_droidFriendsFriendsFriends.
@Test
void test_droidFriendsFriendsFriends() throws GraphQLRequestExecutionException, GraphQLRequestPreparationException {
// droid("{id appearsIn name friends {name friends {friends{id name appearsIn}}}
// primaryFunction }", "2");
Droid d = queries.droidFriendsFriendsFriends("00000000-0000-0000-0000-000000000002");
checkCharacter(d, "testDroidFriendsFriendsFriends", "00000000-0000-0000-0000-000000000002", "BB-8", 2, Episode.NEWHOPE);
assertEquals("Function of BB-8", d.getPrimaryFunction());
// "52", "Poe Dameron"
Character friends_0 = d.getFriends().get(0);
checkCharacter(friends_0, "testDroidFriendsFriendsFriends[friends_0]", null, "Poe Dameron", 0);
// "180", "Luke Skywalker"
Character friends_1 = d.getFriends().get(1);
checkCharacter(friends_1, "testDroidFriendsFriendsFriends[friends_1]", null, "Luke Skywalker", 2);
}