def vm_state_from_status(status):
    for state, task_map in _STATE_MAP.iteritems():
        status_string = task_map.get("default")
        if status.lower() == status_string.lower():
            return state
Test an equality rewrite with non-static values
dataset/ETHPy150Open nii-cloud/dodai-compute/nova/api/openstack/common.py/vm_state_from_status--crossover with--dataset/ETHPy150Open armon/pypred/tests/unit/test_compare.py/TestCompare.test_equality_rewrite_non_static