Fix regexp pretty printing for Chrome.
This commit is contained in:
parent
701ee719e6
commit
23c5289b7e
@ -29,14 +29,14 @@ jasmine.PrettyPrinter.prototype.format = function(value) {
|
||||
this.emitString(value);
|
||||
} else if (jasmine.isSpy(value)) {
|
||||
this.emitScalar("spy on " + value.identity);
|
||||
} else if (value instanceof RegExp) {
|
||||
this.emitScalar(value.toString());
|
||||
} else if (typeof value === 'function') {
|
||||
this.emitScalar('Function');
|
||||
} else if (typeof value.nodeType === 'number') {
|
||||
this.emitScalar('HTMLNode');
|
||||
} else if (value instanceof Date) {
|
||||
this.emitScalar('Date(' + value + ')');
|
||||
} else if (value instanceof RegExp) {
|
||||
this.emitScalar(value.toString());
|
||||
} else if (value.__Jasmine_been_here_before__) {
|
||||
this.emitScalar('<circular reference: ' + (jasmine.isArray_(value) ? 'Array' : 'Object') + '>');
|
||||
} else if (jasmine.isArray_(value) || typeof value == 'object') {
|
||||
|
Loading…
Reference in New Issue
Block a user