Fixed basic tests of functions to reflect API changes in the
way to call R functionx