Added board test and fixed several bugs
changed test minorly