diff --git a/package/__tests__/development.js b/package/__tests__/development.js index 827667d72..3997602c1 100644 --- a/package/__tests__/development.js +++ b/package/__tests__/development.js @@ -14,7 +14,7 @@ describe('Development environment', () => { test('should use development config and environment including devServer if WEBPACK_DEV_SERVER', () => { process.env.RAILS_ENV = 'development' process.env.NODE_ENV = 'development' - process.env.WEBPACK_DEV_SERVER = 'YES' + process.env.WEBPACK_DEV_SERVER = 'true' const { webpackConfig } = require('../index') expect(webpackConfig.output.path).toEqual(resolve('public', 'packs')) diff --git a/test/webpacker_test.rb b/test/webpacker_test.rb index 2aea64014..0fd2d4d35 100644 --- a/test/webpacker_test.rb +++ b/test/webpacker_test.rb @@ -23,8 +23,8 @@ def dev_server.pretty?; false; end def dev_server.https?; true; end def dev_server.hmr?; true; end def dev_server.running?; true; end - Webpacker::DevServer.stub(:new, dev_server) do - assert !Webpacker.inlining_css? + Webpacker.instance.stub(:dev_server, dev_server) do + assert Webpacker.inlining_css? end end end