feat(graphql): added simple graphql service with new backend plugin
This commit is contained in:
@@ -50,7 +50,7 @@
|
||||
"jest-fetch-mock": "^3.0.3",
|
||||
"msw": "^0.19.0",
|
||||
"react-test-renderer": "^16.13.1",
|
||||
"whatwg-fetch": "^3.0.0"
|
||||
"whatwg-fetch": "^2.0.0"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
module.exports = {
|
||||
extends: [require.resolve('@backstage/cli/config/eslint')],
|
||||
extends: [require.resolve('@backstage/cli/config/eslint.backend')],
|
||||
};
|
||||
|
||||
@@ -25,14 +25,15 @@
|
||||
"@types/express": "^4.17.6",
|
||||
"express": "^4.17.1",
|
||||
"express-promise-router": "^3.0.3",
|
||||
"yn": "^4.0.0",
|
||||
"whatwg-fetch": "^3.2.0"
|
||||
"whatwg-fetch": "^2.0.0",
|
||||
"winston": "^3.2.1",
|
||||
"yn": "^4.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@backstage/cli": "^0.1.1-alpha.15",
|
||||
"@types/supertest": "^2.0.8",
|
||||
"supertest": "^4.0.2",
|
||||
"msw": "^0.19.5"
|
||||
"msw": "^0.19.5",
|
||||
"supertest": "^4.0.2"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
|
||||
@@ -15,4 +15,5 @@
|
||||
*/
|
||||
|
||||
require('whatwg-fetch');
|
||||
|
||||
export * from './service/router';
|
||||
|
||||
@@ -34,9 +34,9 @@ describe('createRouter', () => {
|
||||
jest.resetAllMocks();
|
||||
});
|
||||
|
||||
describe('GET /ping', () => {
|
||||
describe('GET /health', () => {
|
||||
it('returns ok', async () => {
|
||||
const response = await request(app).get('/ping');
|
||||
const response = await request(app).get('/health');
|
||||
|
||||
expect(response.status).toEqual(200);
|
||||
expect(response.body).toEqual({ status: 'ok' });
|
||||
|
||||
@@ -14,3 +14,5 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
require('whatwg-fetch');
|
||||
|
||||
export {};
|
||||
|
||||
Reference in New Issue
Block a user