yoastseo-dep
Version:
Yoast clientside page analysis
20 lines (14 loc) • 445 B
JavaScript
import { showTrace } from "../../src/helpers/errors";
describe( "showTrace", function() {
beforeEach( function() {
spyOn( console, "trace" );
} );
it( "should send a message to console.trace", function() {
showTrace( "message" );
expect( console.trace ).toHaveBeenCalledWith( "message" );
} );
it( "should default to an empty message", function() {
showTrace();
expect( console.trace ).toHaveBeenCalledWith( "" );
} );
} );