update test cases, add state class