Merge "add unittest for 'last' query of results in testAPI"