Skip to content

Commit

Permalink
fix: e2e test; typing
Browse files Browse the repository at this point in the history
  • Loading branch information
liximomo committed Jul 9, 2020
1 parent 56c66ff commit 93f98be
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 deletions.
8 changes: 4 additions & 4 deletions packages/toolpack/src/webpack/config/parts/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ export const webpackHelpers = (): IWebpackHelpers => {
callback
) => {
let callbackCalled = false;
const nextHandler = (err?: any, result?: any, type?: string) => {
const nextHandler = (err?: any, result?: any) => {
if (err) {
callback(err);
callback(err, undefined);
callbackCalled = true;
} else {
if (result !== 'next') {
callback(err, result, type);
callback(err, result);
callbackCalled = true;
}
}
Expand All @@ -31,7 +31,7 @@ export const webpackHelpers = (): IWebpackHelpers => {
}

if (!callbackCalled) {
callback();
callback(null, undefined);
}
};

Expand Down
9 changes: 0 additions & 9 deletions test/e2e/runtime-plugin.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,5 @@ describe('Runtime Plugin', () => {
page = await ctx.browser.page(ctx.url('/page-data'));
await page.waitFor('[data-test-id="page-data"]');
expect(await page.$text('[data-test-id="page-data"]')).toBe('bar');

expect(
(
await page.$$eval(
'head > meta[name="testDocumentProps"]',
element => element
)
).length
).toBe(1);
});
});

0 comments on commit 93f98be

Please sign in to comment.