misc bugfixes, started adding web interface unit tests