message: dry test and configurable by env
diff: @@ -2,9 +2,15 @@ const assert = require('assert');
  const rp = require('request-promise');
  const app = require('../<%= src %>/app');
  +const host = process.env.HOST || app.get('host') || 'localhost';
  +const port = process.env.PORT || app.get('port') || 3030;
  +
  +// eslint-disable-next-line no-unused-vars
  +const genURL = path => `http://${host}:${port}/${path || ''}`;
  +
  describe('Feathers application tests', () => {
  before(function(done) {
  - this.server = app.listen(3030);
  + this.server = app.listen(port);
  this.server.once('listening', () => done());
  });
  @@ -13,7 +19,7 @@ describe('Feathers application tests', () => {
  });
  it('starts and shows the index page', () => {
  - return rp('http://localhost:3030').then(body =>
  + return rp(genURL()).then(body =>
  assert.ok(body.indexOf('<html>') !== -1)
  );
  });
  @@ -21,7 +27,7 @@ describe('Feathers application tests', () => {
  describe('404', function() {
  it('shows a 404 HTML page', () => {
  return rp({
  - url: 'http://localhost:3030/path/to/nowhere',
  + url: genURL('path/to/nowhere'),
  headers: {
  'Accept': 'text/html'
  }
  @@ -33,7 +39,7 @@ describe('Feathers application tests', () => {
  it('shows a 404 JSON error without stack trace', () => {
  return rp({
  - url: 'http://localhost:3030/path/to/nowhere',
  + url: genURL('path/to/nowhere'),
  json: true
  }).catch(res => {
  assert.equal(res.statusCode, 404);
  