fixed signedness warnings
authorMartin Vidner <mvidner@suse.cz>
Tue, 12 Jun 2007 11:45:43 +0000 (11:45 +0000)
committerMartin Vidner <mvidner@suse.cz>
Tue, 12 Jun 2007 11:45:43 +0000 (11:45 +0000)
tests/parser/yum/PatchesFileReader_test.cc
tests/parser/yum/RepomdFileReader_test.cc
tests/zypp/Edition.cc

index c972965..033a3f1 100644 (file)
@@ -55,7 +55,7 @@ void patches_read_test(const string &dir)
       
       std::ifstream ifs( file.extend(".solution").asString().c_str() );
       cout << "Comparing to " << file.extend(".solution") << endl;
-      int count = 0;
+      unsigned int count = 0;
       while ( ifs && ! ifs.eof() && count < collect.items.size() )
       {
         string id;
index 874576d..2025089 100644 (file)
@@ -54,7 +54,7 @@ void repomd_read_test(const string &dir)
       
       std::ifstream ifs( file.extend(".solution").asString().c_str() );
       
-      int count = 0;
+      unsigned int count = 0;
       while ( ifs && ! ifs.eof() && count < collect.items.size() )
       {
         string dtype;
index 2ce32d4..3290ac1 100644 (file)
@@ -21,18 +21,18 @@ void edition_test()
   Edition _ed1 ("1");
   Edition _ed2 ("1.1");
   Edition _ed3 ("1:1");
-  Edition _ed4 ("1:1-1");
+  Edition _ed4 ("2:1-1");
 
   BOOST_CHECK_EQUAL(_ed2.version(), "1.1");
   BOOST_CHECK_EQUAL(_ed2.release(), "");
-  BOOST_CHECK_EQUAL(_ed2.epoch(), 0);
-  BOOST_CHECK_EQUAL(_ed4.epoch(), 1);
+  BOOST_CHECK_EQUAL(_ed2.epoch(), 0U);
+  BOOST_CHECK_EQUAL(_ed4.epoch(), 2U);
 
   BOOST_CHECK_EQUAL(_ed1, Edition ("1", ""));
   BOOST_CHECK_EQUAL(_ed2, Edition ("1.1", ""));
   BOOST_CHECK_EQUAL(_ed3, Edition ("1", "", "1"));
   BOOST_CHECK_EQUAL(_ed3, Edition ("1", "", 1));
-  BOOST_CHECK_EQUAL(_ed4, Edition ("1", "1", 1));
+  BOOST_CHECK_EQUAL(_ed4, Edition ("1", "1", 2));
 }
 
 test_suite*
@@ -41,4 +41,4 @@ init_unit_test_suite( int, char* [] )
     test_suite* test= BOOST_TEST_SUITE( "EditionTest" );
     test->add( BOOST_TEST_CASE( &edition_test ), 0 /* expected zero error */ );
     return test;
-}
\ No newline at end of file
+}