-
Notifications
You must be signed in to change notification settings - Fork 93
Dev: Code Coverage Findings
Alex Seaton edited this page Aug 29, 2023
·
1 revision
APIs that are not tested
version_functions.hpp
get_index_and_tombstone_keys
list_streams by prefix
local_versioned_engine.cpp
LocalVersionedEngine::delete_storage
LocalVersionedEngine::latest_timestamp
LocalVersionedEngine::get_update_time_internal
LocalVersionedEngine::scan_object_sizes
LocalVersionedEngine::move_storage
LocalVersionedEngine::force_release_lock
LocalVersionedEngine::batch_write_version_and_prune_if_needed
LocalVersionedEngine::push_incompletes_to_symbol_list
LocalVersionedEngine::get_active_incomplete_refs
LocalVersionedEngine::get_incomplete_refs
LocalVersionedEngine::get_index_range
version_store_api.cpp
PythonVersionStore::batch_write_index_keys_to_version_map
PythonVersionStore::_clear_symbol_list_keys (Probably just needs to be used in PythonVersionStore::reload_symbol_list)
PythonVersionStore::write_partitioned_dataframe
iterate_snapshot_tombstones
PythonVersionStore::get_update_time
PythonVersionStore::fix_symbol_trees
PythonVersionStore::get_version_history
PythonVersionStore::_compact_version_map
PythonVersionStore::compact_library
PythonVersionStore::list_incompletes
PythonVersionStore::empty
VersionedItem update_impl
version_store_api.hpp
fix_ref_key
remove_and_rewrite_version_keys
check_ref_key
python_bindings.cpp
create_library_index
operation_dispatch_binary
quite a few functions are untested
version_map.hpp
dump_entry
compact_if_necessary_stand_alone
overwrite_symbol_tree
arctic_version.cpp
get_arcticdb_version_string - this seems weird
index.hpp
Looks like TableIndex is never used during testing
snapshot.cpp
Looks like the tombstone_snapshot functionality is understested
normalization_checks.cpp
get_pandas_common_via_reflection is not tested properly
version_utils.cpp - is not tested
storages.hpp - looks like we are not testing with multiple storages as backend
append_map.cpp
get_incomplete_refs
get_active_incomplete_refs
latest_incomplete_timestamp
query.hpp - not many tests with RowRanges
write_frame.cpp
write_multi_index
protobuf_mappings.hpp
convert_environment_config
version_log.hpp
log_create_snapshot
log_delete_snapshot
tasks.hpp
struct WriteCompressedTask
struct WriteCompressedBatchTask
Functions with exceptions that are not raised during tests
TombstoneVersionResult tombstone_version
LocalVersionedEngine::get_update_time_internal
LocalVersionedEngine::batch_append_internal
LocalVersionedEngine::append_internal
LocalVersionedEngine::batch_read_internal
LocalVersionedEngine::get_descriptor
LocalVersionedEngine::delete_unreferenced_pruned_indexes
void copy_versions_nearest_to_target
PythonVersionStore::add_to_snapshot
PythonVersionStore::remove_from_snapshot
PythonVersionStore::read_dataframe_merged
PythonVersionStore::delete_snapshot_sync
PythonVersionStore::batch_read_descriptor
Potentially interesting branches that are never tested
False branch of if (opt_latest.has_value()) in std::optional<AtomKey> get_specific_version
The various get_version functions in version_functions.hpp that return std::optional are never tested with the failing branch
False branch of if(!version_queries.empty()) in SpecificAndLatestVersionKeys LocalVersionedEngine::get_stream_index_map
True branch of auto load_param = load_type == LoadType::LOAD_DOWNTO in LocalVersionedEngine::delete_trees_responsibly
LocalVersionedEngine::sort_index is only tested with dynamic_schema=True
Forked option in LocalVersionedEngine is never tested
Writing to PythonVersionStore::write_dataframe_specific_version with a version key that already exists
True branch of if (!user_meta.is_none()) in PythonVersionStore::sort_merge
True branch of else if (opt_false(read_options.force_strings_to_fixed_)) in modify_descriptor
True branch of if (columns_to_keep.empty()) in drop_column_stats_impl
True branch of if(entry->second->load_type_ == LoadType::LOAD_DOWNTO) in has_cached_entry
User: wdealtry
I think
LocalVersionedEngine::get_active_incomplete_refs
LocalVersionedEngine::get_incomplete_refs
is tick streaming functionality, and could maybe be removed.
Same goes for
LocalVersionedEngine::push_incompletes_to_symbol_list
batch_write_version_and_prune_if_needed is only called by batch_write_index_keys_to_version_map, which is no longer the way that we want to do batch write/update/append operations - both of these can be deleted
fix_symbol_trees would be a good one to test, it entirely removes a version list and reconstructs it from the indexes. A handy weapon in the arsenal if we ever had serious version map corruption. A test would just need to write, append, update and delete a bunch of items to the same symbol then call this function - the list of available versions should be exactly the same (although info about deleted versions will now be missing from the version list).
User: aowens
A few comments/questions:
In operation_dispatch_binary, is there a pattern to which functions are untested? For example, we support a lot of operations on (col, val) and (val, col), but I think the Python expression evaluation always produces the (col, val) variant
tombstone_snapshot only makes sense with delayed deletes, which we have in Man Group, but isn't in the open source project as it will be an enterprise feature
multiple storages as backend isn't a supported feature yet
version_log.hpp - these are for replication, which like delayed deletes will be an enterprise feature
write_multi_index - this is slightly worrying, we should correct this
update_impl - also worrying
User: gpetrov
For operation_dispatch_binary, only the (col, val) gets called in testing, the functions that take (val, col) are not hit
ArcticDB Wiki