Fix KeyVaue validator, add ECKeyValue test case.