LCOV - code coverage report
Current view: top level - tests - version.cpp (source / functions) Hit Total Coverage
Test: coverage.info Lines: 7 7 100.0 %
Date: 2019-07-19 13:22:39 Functions: 3 3 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /*
       2             :  * Files:
       3             :  *    tests/version.cpp
       4             :  *
       5             :  * License:
       6             :  *    Copyright (c) 2006-2019  Made to Order Software Corp.  All Rights Reserved
       7             :  *
       8             :  *    https://snapwebsites.org/
       9             :  *    contact@m2osw.com
      10             :  *
      11             :  *    This program is free software; you can redistribute it and/or modify
      12             :  *    it under the terms of the GNU General Public License as published by
      13             :  *    the Free Software Foundation; either version 2 of the License, or
      14             :  *    (at your option) any later version.
      15             :  *
      16             :  *    This program is distributed in the hope that it will be useful,
      17             :  *    but WITHOUT ANY WARRANTY; without even the implied warranty of
      18             :  *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19             :  *    GNU General Public License for more details.
      20             :  *
      21             :  *    You should have received a copy of the GNU General Public License along
      22             :  *    with this program; if not, write to the Free Software Foundation, Inc.,
      23             :  *    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
      24             :  *
      25             :  * Authors:
      26             :  *    Alexis Wilke   alexis@m2osw.com
      27             :  */
      28             : 
      29             : // self
      30             : //
      31             : #include "main.h"
      32             : 
      33             : // libutf8 lib
      34             : //
      35             : #include "libutf8/version.h"
      36             : 
      37             : 
      38             : 
      39             : 
      40           3 : CATCH_TEST_CASE("Version", "[version]")
      41             : {
      42           2 :     CATCH_START_SECTION("verify runtime vs compile time version numbers")
      43             :     {
      44           1 :         CATCH_REQUIRE(libutf8::get_major_version()   == LIBUTF8_VERSION_MAJOR);
      45           1 :         CATCH_REQUIRE(libutf8::get_release_version() == LIBUTF8_VERSION_MINOR);
      46           1 :         CATCH_REQUIRE(libutf8::get_patch_version()   == LIBUTF8_VERSION_PATCH);
      47           1 :         CATCH_REQUIRE(strcmp(libutf8::get_version_string(), LIBUTF8_VERSION_STRING) == 0);
      48             :     }
      49             :     CATCH_END_SECTION()
      50           7 : }
      51             : 
      52             : 
      53             : // vim: ts=4 sw=4 et

Generated by: LCOV version 1.12