MCPcopy Create free account
hub / github.com/comaps/comaps / UNIT_TEST

Function UNIT_TEST

libs/coding/coding_tests/file_data_test.cpp:40–58  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38#endif
39
40UNIT_TEST(FileData_ApiSmoke)
41{
42 MakeFile(name1);
43 uint64_t const size = name1.size();
44
45 uint64_t sz;
46 TEST(base::GetFileSize(name1, sz), ());
47 TEST_EQUAL(sz, size, ());
48
49 TEST(base::RenameFileX(name1, name2), ());
50
51 TEST(!base::GetFileSize(name1, sz), ());
52 TEST(base::GetFileSize(name2, sz), ());
53 TEST_EQUAL(sz, size, ());
54
55 TEST(base::DeleteFileX(name2), ());
56
57 TEST(!base::GetFileSize(name2, sz), ());
58}
59
60/*
61UNIT_TEST(FileData_NoDiskSpace)

Callers

nothing calls this directly

Calls 10

TESTFunction · 0.85
GetFileSizeFunction · 0.85
RenameFileXFunction · 0.85
DeleteFileXFunction · 0.85
IsEqualFilesFunction · 0.85
CopyFileXFunction · 0.85
MakeFileFunction · 0.70
sizeMethod · 0.45
WriteMethod · 0.45
ReadMethod · 0.45

Tested by

no test coverage detected