fix a typo and add a test case about nested hierarchy state transition issue