Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- TEST_CASE("Data was succesfully writed to files", "[data_store]") {
- set_path("C:/Users/TwITe/Documents/Visual Studio 2017/Projects/Database/Data_files/");
- set_data_file_size(5);
- int arr[5]{ 0, 1, 2, 3, 4 };
- REQUIRE(write_data(1, arr, 20) == true);
- }
- TEST_CASE("Data was succesfully deleted", "[data_delete]") {
- set_path("C:/Users/TwITe/Documents/Visual Studio 2017/Projects/Database/Data_files/");
- set_data_file_size(5);
- int arr[5]{ 0, 1, 2, 3, 4 };
- int id = 1;
- write_data(id, arr, 20);
- delete_data(id);
- REQUIRE(indexes[id].deleted == true);
- }
Advertisement
Add Comment
Please, Sign In to add comment