Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Made to work and test on IE7+ #3

Merged
merged 1 commit into from Dec 14, 2012

Conversation

Projects
None yet
2 participants

jpka commented Nov 29, 2012

I changed a lot for the testing part, but not the intent of the actual tests. The code changes themselves are small. If you don't care about IE, let me know and I will make my fork independent.

Owner

badunk commented Dec 1, 2012

Hi - I'll review this today and get back to you. I'm all for supporting IE if this project can reach out to more people

Thanks!

@badunk badunk and 1 other commented on an outdated diff Dec 3, 2012

fixtures.js
@@ -64,7 +59,7 @@ var fixtures = fixtures || new function(){
createContainer(html);
}
else{
- container.contents().find('body').append(html);
+ self.body = container.contents().find('body').append(html).html();
@badunk

badunk Dec 3, 2012

Owner

I don't think this is the same as defining a getter for the body since the body only gets updated when the addToContainer method is called

@jpka

jpka Dec 11, 2012

Yeah, you have a point. Sadly, IEs before 9 have never heard of such a thing as a getter. I believe this calls for an api change, it would do to just change the getters for regular functions, or maybe you have a better idea?

@badunk

badunk Dec 12, 2012

Owner

yep, let's do that, I'll merge in the change if you've got that

Thanks!

@badunk badunk commented on the diff Dec 3, 2012

test/index.html
<script src="../fixtures.js"></script>
<script>
- mocha.setup('bdd');
- var should = chai.should();
- var expect = chai.expect;
+ mocha.setup({
+ ui: 'bdd',
+ globals: ['js-fixtures'] //for IE not to complain
@badunk

badunk Dec 3, 2012

Owner

is there a js-fixtures global being leaked? Why does this need to be defined?

@jpka

jpka Dec 11, 2012

Apparently, Opera and IE expose global variables for HTML element IDs, Mocha even filters out it's own IDs when detecting leaks. (https://github.com/visionmedia/mocha/blob/master/mocha.js#L4265)
It isn't an issue, it's just IE being IE.

jpka commented Dec 13, 2012

There, all done :).

@badunk badunk merged commit 81f4fdb into badunk:master Dec 14, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment