Browse Source

tests: silence -Wmissing-declarations

Gbp-Dch: Ignore
Reported-By: gcc -Wmissing-declarations
David Kalnischkies 7 years ago
parent
commit
d8a57c1953
3 changed files with 3 additions and 7 deletions
  1. 1 5
      test/libapt/commandline_test.cc
  2. 1 1
      test/libapt/strutil_test.cc
  3. 1 1
      test/libapt/tagsection_test.cc

+ 1 - 5
test/libapt/commandline_test.cc

@@ -17,10 +17,6 @@ class CLT: public CommandLine {
       }
 };
 
-bool ShowHelp(CommandLine &) {return false;}
-std::vector<aptDispatchWithHelp> GetCommands() {return {};}
-
-
 TEST(CommandLineTest,SaveInConfig)
 {
 #define APT_EXPECT_CMD(x, ...) { const char * const argv[] = { __VA_ARGS__ }; EXPECT_EQ(x, CLT::AsString(argv, sizeof(argv)/sizeof(argv[0]))); }
@@ -166,7 +162,7 @@ TEST(CommandLineTest, BoolParsing)
 
 }
 
-bool DoVoid(CommandLine &) { return false; }
+static bool DoVoid(CommandLine &) { return false; }
 
 TEST(CommandLineTest,GetCommand)
 {

+ 1 - 1
test/libapt/strutil_test.cc

@@ -168,7 +168,7 @@ TEST(StrUtilTest,Base64Encode)
    EXPECT_EQ("Lg==", Base64Encode("."));
    EXPECT_EQ("", Base64Encode(""));
 }
-void ReadMessagesTestWithNewLine(char const * const nl, char const * const ab)
+static void ReadMessagesTestWithNewLine(char const * const nl, char const * const ab)
 {
    SCOPED_TRACE(SubstVar(SubstVar(nl, "\n", "n"), "\r", "r") + " # " + ab);
    FileFd fd;

+ 1 - 1
test/libapt/tagsection_test.cc

@@ -24,7 +24,7 @@ std::string overrideValue = "1";
    std::cerr << "«" << std::endl;;
 */
 
-void setupTestcaseStart(FileFd &fd, pkgTagSection &section, std::string &content)
+static void setupTestcaseStart(FileFd &fd, pkgTagSection &section, std::string &content)
 {
    createTemporaryFile("writesection", fd, NULL, NULL);
    content = "Package: " + packageValue + "\n"