Joose depends on playing nice with other JS libraries and user code
that does weird stuff.
I have commited an experimental test library called Test.RealWorld to
test this. It still needs to get support from Test.TAPBrowser. I think
the best thing would be to create a new iframe for each method in
Test.RealWorld and then execute it in the iframe before executing all
tests.
Bye the way: While I do not really know this for sure, it is almost
certain that tests will fail after loading Prototype. We might have to
live with that.
What do you think?
bye
Malte
I just implemented this:
You can now call methods out ouf Test.RealWorld using:
test.html#real_world=extendObject
Preliminary results: we suck
- Extending Object breaks us
- Extending Array seems to break at least Moose.Storage.jsonpickle
- We do not run with Prototype
- We do not run with Mootools
The first two will have to be fixed. I am not sure about the latter.
We conflict on several important global variables (Prototype, Class)
and fixing this will be hard (although, not impossible)
Should compatibility with Prototype be a goal or is prototype too legacy?
Malte
From now on, please use
Joose.O.eachSafe instead of Joose.O.each unless neccessary.
Bye
Malte
On Sun, Oct 26, 2008 at 3:18 PM, Malte Ubl <malt...@gmail.com> wrote:
FYI, I thought this might be related to your recent Prototype fun.
I just checked in two coercions for Bool ("true" and "false"), and in my
fresh checkout I noticed that test 14_modules.t.js fails now:
not ok 25 - code threw [ ] expected: [here is already something else]
The line is :
self.throws_ok(function () {com.test.module.meta.alias(thistop)}, "here
is already something else", "Importing fails if there is already
something else")
Cheers,
Mike