add missing test case, fixing implementation