def test_remap_categories():
    feature_stats = {1: 22.343, 2: 54.34, 3: 987.5}
    category_map = {1: 'grassland', 2: 'forest'}
    new_stats = remap_categories(category_map, feature_stats)
    assert 1 not in new_stats.keys()
    assert 'grassland' in new_stats.keys()
    assert 3 in new_stats.keys()
dataset/ETHPy150Open perrygeo/python-rasterstats/tests/test_utils.py/test_remap_categories/original