@@ -3,21 +3,24 @@ import { createTenv } from '@e2e/tenv';
3
3
import { fetch } from '@whatwg-node/fetch' ;
4
4
import { getAvailablePort } from '../../packages/testing/getAvailablePort' ;
5
5
6
- const { compose, serve , service } = createTenv ( __dirname ) ;
6
+ const { compose, gateway , service } = createTenv ( __dirname ) ;
7
7
8
- it ( 'should compose the appropriate schema' , async ( ) => {
8
+ it . concurrent ( 'should compose the appropriate schema' , async ( ) => {
9
9
const api = await service ( 'api' ) ;
10
- const { result } = await compose ( { services : [ api ] , maskServicePorts : true } ) ;
10
+ const { supergraphSdl : result } = await compose ( { services : [ api ] , maskServicePorts : true } ) ;
11
11
expect ( result ) . toMatchSnapshot ( ) ;
12
12
} ) ;
13
13
14
14
[ 'todoAddedFromSource' , 'todoAddedFromExtensions' ] . forEach ( subscriptionField => {
15
15
describe ( `Listen to ${ subscriptionField } ` , ( ) => {
16
- it ( 'should query, mutate and subscribe' , async ( ) => {
16
+ it . concurrent ( 'should query, mutate and subscribe' , async ( ) => {
17
17
const servePort = await getAvailablePort ( ) ;
18
18
const api = await service ( 'api' , { servePort } ) ;
19
- const { output } = await compose ( { output : 'graphql' , services : [ api ] } ) ;
20
- const { hostname, port, execute } = await serve ( { supergraph : output , port : servePort } ) ;
19
+ const { supergraphPath } = await compose ( { output : 'graphql' , services : [ api ] } ) ;
20
+ const { hostname, port, execute } = await gateway ( {
21
+ supergraph : supergraphPath ,
22
+ port : servePort ,
23
+ } ) ;
21
24
22
25
await expect (
23
26
execute ( {
0 commit comments