Re: [Evolution-hackers] Rethinking account management
- From: Matthew Barnes <mbarnes redhat com>
- To: Patrick Ohly <patrick ohly gmx de>
- Cc: evolution-hackers gnome org
- Subject: Re: [Evolution-hackers] Rethinking account management
- Date: Thu, 27 Jan 2011 08:16:46 -0500
On Thu, 2011-01-27 at 08:15 +0100, Patrick Ohly wrote:
> On Mi, 2011-01-26 at 11:34 -0500, Matthew Barnes wrote:
> > Can you elaborate on the creation use case? Sounds like you're creating
> > local data sources on the fly?
>
> Yes. The primary use case is in automated testing. Instead of having to
> create the database in advance via the GUI, the test driver does it
> automatically.
For automated testing you could either predefine a set of key files --
each of which pointing to a different .ics file -- or generate the key
files on the fly. Haven't nailed down the exact format of the backend
group yet but it would look something like:
[Data Source]
Parent=local
DisplayName=Test 1
[Calendar]
Color=#whatever
Enabled=true
[File Backend]
Location=file://path/to/test.ics
The test fixture would then load the directory containing these key
files into the registry:
ESourceRegistry *registry;
GList *sources, *iter;
registry = e_source_registry_get_default ();
e_source_registry_load_directory (registry,
"/path/to/key-files");
/* Give me all the test ESources. */
sources = e_sources_registry_list_sources (registry, NULL);
/* Run each test. */
for (iter = sources; iter != NULL; iter = g_list_next (iter))
run_test (E_SOURCE (iter->data));
g_list_free (sources);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]