github.com/fortexxx/gqlgen@v0.10.3-0.20191216030626-ca5ea8b21ead/.circleci/check-integration (about)

     1  #!/bin/bash
     2  
     3  set -euo pipefail
     4  
     5  cd integration
     6  
     7  go run ./server/server.go &
     8  
     9  sleep 2
    10  
    11  echo "### running jest integration spec"
    12  ./node_modules/.bin/jest --color
    13  
    14  
    15  echo "### validating introspected schema"
    16  SERVER_URL=http://localhost:8080/query ./node_modules/.bin/graphql get-schema
    17  
    18  if ! diff <(tail -n +3 schema-expected.graphql) <(tail -n +3 schema-fetched.graphql) ; then
    19      echo "The expected schema has changed, you need to update schema-expected.graphql with any expected changes"
    20      exit 1
    21  fi