From b79f8458426ac42e284f5f821b265540760d7999 Mon Sep 17 00:00:00 2001 From: Pooya Parsa Date: Wed, 14 Jun 2017 00:45:06 +0430 Subject: [PATCH] update tests --- test/fixtures/module/modules/template/index.js | 2 +- test/module.test.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/test/fixtures/module/modules/template/index.js b/test/fixtures/module/modules/template/index.js index 7e85b80d56..4ae607b4b6 100644 --- a/test/fixtures/module/modules/template/index.js +++ b/test/fixtures/module/modules/template/index.js @@ -2,7 +2,7 @@ const path = require('path') module.exports = function () { // Disable parsing pages/ - this.nuxt.createRoutes = () => {} + this.nuxt.options.build.createRoutes = () => {} // Add /api endpoint this.addTemplate({ fileName: 'router.js', diff --git a/test/module.test.js b/test/module.test.js index 59fd0c4ee3..14b79171c8 100755 --- a/test/module.test.js +++ b/test/module.test.js @@ -26,7 +26,8 @@ test('Vendor', async t => { }) test('Plugin', async t => { - t.true(nuxt.options.plugins[0].src.includes(normalize('fixtures/module/.nuxt/basic.reverse.')), 'plugin added to config') + t.true(normalize(nuxt.options.plugins[0].src) + .includes(normalize('fixtures/module/.nuxt/basic.reverse.')), 'plugin added to config') const { html } = await nuxt.renderRoute('/') t.true(html.includes('

TXUN

'), 'plugin works') })