This test depends on threading.
When I put a breakpoint into Installer.writeOut() method and run the test under debugger, it fails after the thread is suspended on the breakpoint.
It randomly fails in the test environment - see http://deadlock.netbeans.org/hudson/job/NB-Core-Build/8102/console
1 tests failed.
One record for disabled and one for enabled:  expected:<2> but was:<0>
junit.framework.AssertionFailedError: One record for disabled and one for enabled:  expected:<2> but was:<0>
Apparently, to wait 1s in lastRecord.waitFinished(1000); is not enough.
The waitFinished(1000) is called two times in the test - once from installer.closing() and once from Installer.getLogs(). Thus even 2s wait time is not enough. There is really an extremely slow threads execution on the testing machine.
Why is there the timeout at all? It does not wait till flushed with the timeout, thus breaking the contract.
The timeout is changed to indefinite in changeset: 217960:3febf5809ae5
Integrated into 'main-golden', will be available in build *201204060400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Log: testSetOfEnabledModulesIsListed() marked as @RandomlyFails until issue #210773 is fixed.