-
-
Notifications
You must be signed in to change notification settings - Fork 570
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(graphql): added support for auto-exporting the schema (#347)
* Added support for auto-exporting the schema Supports .json and .graphql formats. Tests are WIP. * Made the requested changes Also fixed the tests by manually defining the mocked method. * Fixed CI errors, added a change I forgot to commit * Update postgraphql.ts * Update postgraphql.ts * Rename pathgraphqlIntegrationSchemaExport-test.js to postgraphqlIntegrationSchemaExport-test.js * Rename pathgraphqlIntegrationSchemaExport-test.js.snap to postgraphqlIntegrationSchemaExport-test.js.snap * Update postgraphql.ts
- Loading branch information
Showing
8 changed files
with
3,223 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
const fs = require.requireActual('fs') | ||
|
||
// Mock the writeFile for the export tests | ||
const writeFile = jest.fn((path, contents, callback) => { | ||
callback() | ||
}) | ||
|
||
module.exports = { | ||
...fs, | ||
writeFile, | ||
} |
Oops, something went wrong.