Class for unit testing code that uses Math.random.
extends goog.Disposable| Instance Method Summary | |
disposeInternal()Deletes or nulls out any references to COM objects, DOM nodes, or other disposable objects. Classes that extend {@code goog.Disposable} should override this method. Not reentrant. To avoid calling it twice, it must only be called from the subclass' {@code disposeInternal} method. Everywhere else the public {@code dispose} method must be used. For example:
mypackage.MyClass = function() {
goog.base(this);
// Constructor logic specific to MyClass.
...
};
goog.inherits(mypackage.MyClass, goog.Disposable);
mypackage.MyClass.prototype.disposeInternal = function() {
goog.base(this, 'disposeInternal');
// Dispose logic specific to MyClass.
...
};
| |
hasMoreValues() ⇒ boolean | |
inject((Array|null|number) values)Injects new numbers into the beginning of the sequence. | |
install()Installs this MockRandom as the system number generator. | |
random() ⇒ number | |
uninstall()Uninstalls the MockRandom. | |