mockolate icon indicating copy to clipboard operation
mockolate copied to clipboard

Add constructor overrides for special cases like NetStream

Open drewbourne opened this issue 14 years ago • 0 comments

Something like:

mocks.addConstructorOverrideFor(NetStream, function(netStreamClass:Class, constructorArgs:Array):NetStream {
    var netConnection:NetConnection = new NetConnection();
    netConnection.connect(null);
    return new netStreamClass(netConnection)
});

drewbourne avatar Sep 15 '11 04:09 drewbourne