applait / finderjs

Finder and file picker library for Firefox OS
http://finder.js.org
MIT License
14 stars 7 forks source link

Write tests for log method #10

Closed kaustavdm closed 9 years ago

kaustavdm commented 9 years ago
kumarrishav commented 9 years ago

@kaustavdm do you mean test case will be for all three case or only for first and third? is there need of any test case for second one?

dolftax commented 9 years ago

@kumarrishav, this should help, right?

expect(foo.args.length).toEqual(2);

kumarrishav commented 9 years ago

PR on the top of Fixes -#9

kaustavdm commented 9 years ago

@kumarrishav The second case tests that we don't accidentally change the internal API of the log method. Otherwise all the other methods calling log may start failing.

kaustavdm commented 9 years ago

@jaipradeesh Yes.

kaustavdm commented 9 years ago

@jaipradeesh @kumarrishav Man oh man oh man! Why didn't I see sense here??!

Using finder.debugmode = true makes full sense. In fact, that is something we need to put in the README.md. We don't need to have a setattribute method.

kumarrishav commented 9 years ago

@kaustavdm I didn't get this. Is this related to PR (except updating patch to master).