juniper/integration_tests/codegen_fail/fail/interface/impl_unqiue_name.rs.disabled

30 lines
575 B
Text
Raw Normal View History

#[derive(juniper::GraphQLObject)]
#[graphql(scalar = juniper::DefaultScalarValue)]
pub struct ObjA {
test: String,
}
enum Character {
A(ObjA),
}
juniper::graphql_interface!(Character: () where Scalar = juniper::DefaultScalarValue |&self| {
field id() -> &str {
match *self {
Character::A(_) => "funA",
}
}
field id() -> &str {
match *self {
Character::A(_) => "funA",
}
}
instance_resolvers: |_| {
&ObjA => match *self { Character::A(ref h) => Some(h) },
}
});
fn main() {}