test code for Gambit