example code and test scripts