various fixups
adding integration test