diff --git a/tests/ExampleTests.cpp b/tests/ExampleTests.cpp index 2c4d77d03db743730f98d6b06718b8a8606f4fb2..a661d2fe2c8382e76c3cda075a88b60a2eb230d8 100644 --- a/tests/ExampleTests.cpp +++ b/tests/ExampleTests.cpp @@ -58,7 +58,7 @@ TEST(ExampleTests, test_write_results) { write_results(&counter, "output.txt"); cleanup_frequency_counter(&counter); // check the output file - FILE *f = fopen("./output.txt", "r"); + FILE *f = fopen("output.txt", "r"); char line[100]; fgets(line, 100, f); EXPECT_STREQ("hello 3\n", line); @@ -72,10 +72,10 @@ TEST(ExampleTests, test_write_results) { TEST(ExampleTests, test_filter_stop_words) { FrequencyCounter counter; init_frequency_counter(&counter); - read_and_count_words(&counter, "./test.txt"); + read_and_count_words(&counter, "test.txt"); sort_words_by_frequency(&counter); - filter_stop_words(&counter, "./stopwords.txt"); - write_results(&counter, "./output.txt"); + filter_stop_words(&counter, "stopWords.txt"); + write_results(&counter, "output.txt"); EXPECT_EQ(3, counter.count); EXPECT_STREQ("hello", counter.words[0].word); EXPECT_EQ(3, counter.words[0].frequency); @@ -85,7 +85,7 @@ TEST(ExampleTests, test_filter_stop_words) { } TEST(ExampleTests, test_count_words_in_file) { - EXPECT_EQ(6, count_words_in_file("./test.txt")); + EXPECT_EQ(6, count_words_in_file("test.txt")); } //TEST(ExampleTests, test_read_and_count_ngrams) {