rebuild, finishing touches on tests and lib