Re: Write to disk in Platform based JUnit tests
Tim Boudreau <[email protected]>
| Newsgroups | gmane.comp.java.netbeans.modules.openide.devel |
|---|---|
| Message-ID | <CA+qecRNd=dXcPW=15g_qkneS_8VuEZFPBtZH2gZo=MUXnwJu1g@mail.gmail.com> |
There used to be a way to set the class used for Repository.getDefault() (provides the system fs) via a system property or perhaps via setting the default lookup via system property - something like that - I remember doing it in a test circa 2004. -Tim On Fri, Dec 4, 2015 at 1:45 AM, mhaslinger <[email protected]> wrote: > I want to create the new file in the user directory, so the one where NB > Platform according to documentation writes all its delta from the embedded > layer.xml data. (The one where also Windows2Local folder is placed - btw > what is needed that this Folder is initialized for test runs?) > At normal runtime this just workes fine but during test runs a virtual > nbfs file is created instead of a real file on disk. > > I have looked at getting a partial initialized Environment for testing but > I could not achieve to reduce the number of started modules to a subset (I > only want to use the module under test and its dependencies of course, but > not all other modules - but they all get started) > > > > > -- http://timboudreau.com