-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Reuse test windows during integration suites #4618
Conversation
@TomMalbran want to review? |
.done(function (result) { | ||
allFiles = result; | ||
}); | ||
describe("multiple requests", function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes in this file look bad, but I simply isolated the following 2 specs since they can't share a test window with others:
- should handle differing simultaneous requests without doing extra work
- should handle identical simultaneous requests without doing extra work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can add ?w=1
to the github URL for the file diff to get it to ignore whitespace. (Unfortunately you can't comment in that view.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, that make it much easier to review it.
It would be great to have a diff that showed different the code that was moved around. Makes the diff huge and nothing really changed.
@jasonsanjose Done with an initial review. I am seeing a failure in |
I'm actually seeing a different failure in that spec
|
I haven't seen that error, but I still get the one I mentioned. Occasionally it doesn't appear. The weird part is that the file stills open and the live development is done. One thing I noticed is that |
I was somehow able to get the same failure that you mention and also saw it at Increasing the files to open timeout to 1000 seems to have fixed the other failure I mentioned. |
I'm trying to fix the failure in |
Hmm, I tried calling in I prefer |
@TomMalbran ready for review. I fixed the inline editor test failure and after increasing the timeout I haven't reproduce the live dev failures. |
When running the live development test, without closing the window at the end, check the files. Open "simple1.css" into the working set, and you should see it dirty. Maybe the Document/Editor was never destroyed. I actually tried using I'll check the new changes. |
Ok, I'll try that out. I had to back out one change to DocumentCommandHandlers-test because the spies on Dialog prevented |
Sounds good. If the test don't care about the content of the file, like the DocumentCommandHandler tests, DocumentManager.closeAll is good. We could also update FILE_CLOSE_ALL to receive a dontShowUI option so that it doesn't show it. I still don't get why I can see the older changes when reopening the files. The InlineEditors tests work fine. Wasn't able to reproduce the failure. But I did still saw the timeout in the Live Development tests since the default timeout is 1000 and the new timeout is still 1000. I haven't seen any errors with 5000 or 10000 as a timeout on files. By the way, at which amount of commits we ask for a rebase? |
…nager and live dev fix jshint error code review comments optimize project rewrite for inlineeditor tests fix failing inline editor test by forcing FileIndexManager to sync replace closeAllDocuments with closeAllFiles increase timeout for openProjectFiles Use DocumentManager.closeAll() to prevent accidental usage of spies set in Dialog.showSaveDialog
Just rebased! :) I'm happy with these changes even with that one live development failure. If you're happy and want to merge I can see if this improves run time on our build machines. |
Sure, maybe the test run a bit slower on my computer with all the stuff I have open anyway. And the test doesn't always fail. Merging. |
…dows Reuse test windows during integration suites
Let me know if it improved or if anything failed :) |
Much improved so far. Finished under 6 minutes on windows and under 4 minutes on mac. I'll need a few more test runs to feel confident. For the last month or so they would hit the 15min timeout. Our current theory is that we've got a memory leak (#4185) that is magnified in the test runs due to how many new windows we open. |
Awesome :) I was checking |
CodeHintManager._removeHintProvider
method to restoreCodeHintManager
state for unit tests