File tree Expand file tree Collapse file tree 1 file changed +18
-2
lines changed Expand file tree Collapse file tree 1 file changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,22 @@ chai.use(chaiAsPromised);
2323
2424const expect = chai . expect ;
2525
26+ /*
27+ // Schema
28+ type User @table (key: "uid") {
29+ uid: String!
30+ name: String!
31+ address: String!
32+ }
33+
34+ type Email @table {
35+ subject: String!
36+ date: Date!
37+ text: String!
38+ from: User!
39+ }
40+ */
41+
2642interface UserResponse {
2743 user : {
2844 name : string ;
@@ -59,7 +75,7 @@ interface EmailsResponse {
5975}
6076
6177interface UserVariables {
62- id : string ;
78+ id : { uid : string } ;
6379}
6480
6581const connectorConfig : ConnectorConfig = {
@@ -117,7 +133,7 @@ describe('getDataConnect()', () => {
117133 it ( 'executeGraphql() successfully executes a GraphQL query with variables' , async ( ) => {
118134 const resp = await getDataConnect ( connectorConfig ) . executeGraphql < UserResponse , UserVariables > (
119135 queryGetUserById ,
120- { variables : { id : userId } }
136+ { variables : { id : { uid : userId } } }
121137 ) ;
122138 expect ( resp . data . user . name ) . to . be . not . undefined ;
123139 expect ( resp . data . user . uid ) . equals ( userId ) ;
You can’t perform that action at this time.
0 commit comments