replaced hardcoded sqlite2 functions in the tests