List类
关键字 | 说明 |
---|---|
convert_to_list | 转换为python的list类型 |
append_to_list | 将元素加入列表 |
insert_into_list | 将元素插入列表指定位置 |
combine_lists | 将列表按顺序合并 |
set_list_value | 设置列表指定位置的值 |
remove_values_from_list | 去除列表中指定Values |
remove_from_list | 去除列表中指定位置的值 |
remove_duplicates | 对列表去重 |
get_from_list | 获取列表中指定位置的值 |
get_slice_from_list | 获取列表中指定位置范围内的值 |
count_values_in_list | 获取元素在列表中出现的次数 |
get_index_from_list | 获取元素在列表中第一次出现的位置 |
copy_list | 复制列表 |
reverse_list | 翻转列表 |
sort_list | 列表排序 |
list_should_contain_value | 判断列表应该包含某元素 |
list_should_not_contain_value | |
list_should_not_contain_duplicates | 判断列表不应存在重复值 |
lists_should_be_equal | 判断列表是否相等 |
list_should_contain_sub_list | 判断列表是否包含子列表 |
log_list | 打印列表信息 |
Dictionary类
关键字 | 说明 |
---|---|
convert_to_dictionary | 转换为python的字典类型 |
set_to_dictionary | 将键值对加入字典 |
remove_from_dictionary | 从字典中去除指定key |
pop_from_dictionary | 从字典中去除指定key并返回对应的Value |
keep_in_dictionary | 只保留key,去除其他所有 |
copy_dictionary | 复制字典 |
get_dictionary_keys | 获取字典的key列表 |
get_dictionary_values | 获取字典的value列表 |
get_dictionary_items | 获取字典的键值对列表 |
get_from_dictionary | 获取字典中key对应的value |
dictionary_should_contain_key | 判断字典应该包含key |
dictionary_should_not_contain_key | |
dictionary_should_contain_item | 判断字典应该包含键值对 |
dictionary_should_contain_value | 判断字典应该包含value |
dictionary_should_not_contain_value | |
dictionaries_should_be_equal | 判断字典是否相等 |
dictionary_should_contain_sub_dictionary | 判断字典是否包含子字典 |
log_dictionary | 打印字典的大小和内容 |