The goog.testing.mockmatchers.TypeOf Class

goog.testing.mockmatchers.TypeOf
> goog.testing.mockmatchers.ArgumentMatcher

goog.testing.mockmatchers.TypeOf(type)

A matcher that verifies that an argument is of a given type (e.g. "object").

type {string}
The type that a given argument must have.

.matches(toVerify, opt_expectation)

Inherited from goog.testing.mockmatchers.ArgumentMatcher .

A function that takes a match argument and an optional MockExpectation which (if provided) will get error information and returns whether or not it matches.

toVerify {*}
The argument that should be verified.
opt_expectation {goog.testing.MockExpectation?=}
The expectation for this match.
returns {boolean}
Whether or not a given argument passes verification.