Skip to content

Latest commit

 

History

History
75 lines (75 loc) · 2.92 KB

todo.org

File metadata and controls

75 lines (75 loc) · 2.92 KB

Refactor spy [4/4]

Introduce args, returnValues, thisValues, exceptions arrays

Move getCall() to build calls on-the-fly

Remove this.calls

NFE in SpyCall

JsLint [3/3]

Update lint configuration on source files

Add configuration to and clean up test files

Alias TestCase to testCase to avoid annoying warning

Add missing spy functionality [8/8]

returned

alwaysCalledOn

alwaysCalledWith

alwaysCalledWithExactly

alwaysThrew

calledOnce

calledTwice

calledThrice

Stubs [8/8]

Add callsArg/invokesCallback/callsCallback

Add callsArgWith

Add stub(object) to stub everything

Fail or warn when trying to stub a method that does not exist (avoid typos in stubbed methods etc)

Fail or warn when calling stub with a function: sinon.stub(function () {}); to avoid mistaking sinon.stub for sinon.test

Better naming in error messages

Guess name of fake

Should not be able to stub stubbed/spied/mocked method

Assertions [4/4]

assertNotCalled

assertCalledOnce

assertCalledTwice

assertCalledThrice

Collections [3/3]

Add sinon.collection

Refactor sinon.test to use sinon.collection

Extract sinon.test to own file

Asserts [2/2]

Find all spy methods not exposed as asserts

Reduce duplication

Fakes/Utilities [7/7]

Add FakeXMLHttpRequest

Add Sinon tools to work with FakeXMLHttpRequest

Add fake server

Add fake timers

Add fake Date

Add Clock to control timers and date

Add Sinon tools to work with fake timers

Fix failing test cases in IE [4/4]

StubCallsArgTest

SetTimeOutTest

SpyExceptionsTest

SpyReturnValuesTest

Sandboxes [10/10]

Add sinon.sandbox

Should inherit collection

Should offer to fake timers

Should offer to fake XHR

Should return object with bound spy, stub and mock functions as well as clock and server properties

Allow configuration to provide timer properties to fake

Allow configuration to provide which fake server to use

Check argument to sinon.test()

Check arguments to sinon.testCase()

Remove sinon.testCase nesting feature

Fake timers [6/6]

Fake Date by default

Timers should be executed in the order they are scheduled

Ticking the clock should keep Date up to date on every timer

tick: Don’t recalculate starting point to avoid dropping timers

tick: Don’t fire any callbacks until all timers have been figured out to ensure call order

Add simple parser to grok time strings

Spies [2/2]

Implement called before on individual calls

Should not be able to spy stubbed/spied/mocked method

Configurable sandboxes [0/1]

Go through tests for sinon.test after sandbox refactoring