Fix unit tests to work with new HSQLDB version.

* Configure an EntityManager in a non-deprecated manner.

* Newer versions of HSQLDB require tables names to not have a "$"
in them which they will if the class name for our inner class entities
is used.

* Set a long length for certificate columns.  Note that the length
attribute on the @Column annotation is only used for generated DDL.
See http://stackoverflow.com/a/2876318