Skip to content

Commit c8e2f0f

Browse files
committed
feat(gen): test helper does accepts escaped template strings
1 parent 2f4b76f commit c8e2f0f

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

Diff for: app/index.js

+2
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ var AngularFullstackGenerator = yeoman.generators.Base.extend({
2828

2929
// dynamic assertion statement
3030
this.does = this.is = function(foo) {
31+
foo = this.engine(foo.replace(/\(;>%%<;\)/g, '<%')
32+
.replace(/\(;>%<;\)/g, '%>'), this);
3133
if (this.filters.should) {
3234
return foo + '.should';
3335
} else {

Diff for: script-base.js

+2
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ var Generator = module.exports = function Generator() {
2525

2626
// dynamic assertion statement
2727
this.does = this.is = function(foo) {
28+
foo = this.engine(foo.replace(/\(;>%%<;\)/g, '<%')
29+
.replace(/\(;>%<;\)/g, '%>'), this);
2830
if (this.filters.should) {
2931
return foo + '.should';
3032
} else {

0 commit comments

Comments
 (0)