add test suite

On Sun, Aug 24, 2014 at 11:24:04PM -0700, Josef Reidinger wrote:
> In src/lib/fonts/fonts-config-state.rb:
> 
> > @@ -211,14 +216,36 @@ def initialize
> >            "subpixel_layout" => SUBPIXEL_LAYOUTS[0],
> >          },
> >        }
> > -      load_preset("default")
> > +
> > +    # fpl ~ family preference lists
> 
> is it neccessary to be all of them accessors? Maybe attr_reader is enough as
> this interface is quite dangerous that someone change attribute and break
> consistency of object.

Ok, I think I have implemented all of suggestions you gave me except
that one, so far.

Well, I could rewrite FontsConfigState to some sort of struct,
nevertheless I need better motivation for that from you, ruby
specialists, as that would not take zero amount of time.

When I was a young boy, I had learned that object should not expose
its variables to the world but use functions to read or write them. I
wrote very few classes until now, but, if I must, I had always this
golden rule on my mind.

Now I come to ruby and have figured out that pure read and write
functions can be shotcut'ed by attr_accessor. Why this is dangerous,
please? Should I rewrite accessor functions in some way? Where can an
inconsistency happen at all, keeping in mind that this is just a 
container of config elements, which can be read, then altered 
in any way and written at the end. What will change when struct 
would be used?

I would like to keep object layout for FontsConfigState as I like it
that way. Is there other way out? And where I did a mistake when I
decided to attr_accessor? 

Thanks!