Fixed widows tests
This commit is contained in:
		@@ -135,7 +135,6 @@ static void test_rotate(int days_to_run, uint16_t max_days, uint16_t expected_n_
 | 
			
		||||
 | 
			
		||||
TEST_CASE("daily_logger rotate", "[daily_file_sink]")
 | 
			
		||||
{
 | 
			
		||||
 | 
			
		||||
    int days_to_run = 1;
 | 
			
		||||
    test_rotate(days_to_run, 0, 1);
 | 
			
		||||
    test_rotate(days_to_run, 1, 1);
 | 
			
		||||
 
 | 
			
		||||
@@ -80,11 +80,12 @@ std::size_t count_files(const std::string &folder)
 | 
			
		||||
    HANDLE hFind = INVALID_HANDLE_VALUE;
 | 
			
		||||
 | 
			
		||||
    // Start iterating over the files in the path directory.
 | 
			
		||||
    hFind = ::FindFirstFileA(folder.c_str(), &ffd);
 | 
			
		||||
    hFind = ::FindFirstFileA((folder + "\\*.*").c_str(), &ffd);
 | 
			
		||||
    if (hFind != INVALID_HANDLE_VALUE)
 | 
			
		||||
    {
 | 
			
		||||
        do // Managed to locate and create an handle to that folder.
 | 
			
		||||
        {
 | 
			
		||||
             if (ffd.cFileName[0] != '.')
 | 
			
		||||
                counter++;            
 | 
			
		||||
        } while (::FindNextFile(hFind, &ffd) == TRUE);
 | 
			
		||||
        ::FindClose(hFind);
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user