Custom tracers specs: Simplify code slightly

redux
David Majda 9 years ago
parent 671c22e80f
commit 1d38b973ee

@ -1,4 +1,4 @@
/* global describe, expect, it, PEG, spyOn */
/* global describe, expect, it, jasmine, PEG, spyOn */
"use strict";
@ -74,9 +74,7 @@ describe("generated parser API", function() {
describe("custom tracers", function() {
describe("trace", function() {
it("receives tracing events", function() {
var tracer = { trace: function() { } };
spyOn(tracer, "trace");
var tracer = jasmine.createSpyObj("tracer", ["trace"]);
parser.parse("b", { tracer: tracer });

Loading…
Cancel
Save