Thanks for looking into these Antranig. I ran the test 50+ times and did get a
single failure on my machine. I think the 200ms timeout is working better.
Thanks
Justin
On 2011-09-21, at 1:10 AM, Antranig Basman wrote:
> Thanks for checking this out, Justin - it really is a deeply unsatisfactory
> way of testing the component but unfortunately it is hard to do much better
> without refactoring the base component significantly and/or improving the
> core framework which we don't have time for right now. I increased the
> timeout to 200ms in the meantime in my commit, let me know whether it is
> better enough on that configuration.
> I also pushed the linting fix you mentioned,
> Antranig
>
> On 20/09/2011 11:56, Justin Obara wrote:
>>> + function testToCEnhancement(innerThat, uiOptionsLoader,
>>> innerUIOptions) {
>>> + uiOptions = innerUIOptions;
>>> + }
>>> +
>>> + function testToCEnhancement2() {
>>> + fluid.tests.uiOptions.applierRequestChanges(uiOptions,
>>> testSettings);
>>> + jqUnit.expect(1);
>>> + // TODO: Very unsatisfactory - the TOC resources are the final
>>> thing we wait on, and the
>>> + // event for this is very deeply buried
>>> + setTimeout(function () {
>>> + var container = uiOptions.preview.enhancerContainer;
>>> + var links = $(".flc-toc-tocContainer a", container);
>>> + jqUnit.assertTrue("ToC links created", links.length> 0);
>>> + start();
>>> + }, 100);
>>> + }
>>
>> I ran this test in FF 6 on Mac OS 10.7 and it fails from time to time.
>> Guessing it's a timing issue. Maybe the delay needs to be longer or a
>> different approach taken. It does seem to work most of the time though.
>>
>
_______________________________________________________
fluid-work mailing list - [email protected]
To unsubscribe, change settings or access archives,
see http://lists.idrc.ocad.ca/mailman/listinfo/fluid-work