'use strict';

const stringUtil = require('ember-cli-string-utils');

const useTestFrameworkDetector = require('../test-framework-detector');

module.exports = useTestFrameworkDetector({
  description: 'Generates a controller unit test.',
  locals: function(options) {
    let dasherizedModuleName = stringUtil.dasherize(options.entity.name);
    let controllerPathName = dasherizedModuleName;
    return {
      controllerPathName: controllerPathName,
      friendlyTestDescription: ['Unit', 'Controller', dasherizedModuleName].join(' | ')
    };
  }
});

'use strict';

const stringUtil = require('ember-cli-string-utils');
const testInfo = require('ember-cli-test-info');

const useTestFrameworkDetector = require('../test-framework-detector');

module.exports = useTestFrameworkDetector({
  description: 'Generates a controller unit test.',
  locals: function(options) {
    let dasherizedModuleName = stringUtil.dasherize(options.entity.name);
    let controllerPathName = dasherizedModuleName;
    return {
      controllerPathName: controllerPathName,
      friendlyTestDescription: testInfo.description(options.entity.name, 'Unit', 'Controller')
    };
  }
});

--- 
+++ 
@@ -1,6 +1,7 @@
 'use strict';
 
 const stringUtil = require('ember-cli-string-utils');
+const testInfo = require('ember-cli-test-info');
 
 const useTestFrameworkDetector = require('../test-framework-detector');
 
@@ -11,7 +12,7 @@
     let controllerPathName = dasherizedModuleName;
     return {
       controllerPathName: controllerPathName,
-      friendlyTestDescription: ['Unit', 'Controller', dasherizedModuleName].join(' | ')
+      friendlyTestDescription: testInfo.description(options.entity.name, 'Unit', 'Controller')
     };
   }
 });
blueprints/controller-test: Use dasherizedModuleName for test description
