assertj / assertj/assertj-swing

Support for save/restore preferences (issue 175)

Open
#104 0 comments 0 reactions 0 assignees View on GitHub
import from fest-swing Minor New Feature
Dominant language
Java
Stars
121
Forks
52
PR merge metrics
No merged PRs in 30d

Description

_Issue by **[Alex Ruiz](http://jira.codehaus.org/secure/ViewProfile.jspa?name=alexruiz)** from Tue, 3 Mar 2009 19:48:22 -0600_
_Originally opened as http://jira.codehaus.org/browse/FEST-33_

---

From Simeon Fitch:

Several of my higher level GUI components store state in the java.util.prefs.Preferences service. Several tests directly or indirectly modify the Preferences store, leaving behind "artifacts" of

the test runs, which I'd like to avoid. I'm exploring options for backup up and restoring (or pushing/popping) the preferences state in the @Before/@After or @BeforeClass/@AfterClass methods.

I'm curious to know if anyone else has tackled this, or if there are plans to have it included in FEST-Swing.

If not, I'm considering using the Preferences.exportSubtree(OutputStream) and Preferences.importPreferences(InputStream) methods to save/restore from a temporary file. Any thoughts or recommendations?


Original report: Issue 175 (Google Code)

---

votes (original issue): 0
watches (original issue): 0

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.