LCOV - code coverage report
Current view: top level - test - test-ipcrm.c (source / functions) Hit Total Coverage
Test: systemd_full.info Lines: 0 11 0.0 %
Date: 2019-08-23 13:36:53 Functions: 0 1 0.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 8 0.0 %

           Branch data     Line data    Source code
       1                 :            : /* SPDX-License-Identifier: LGPL-2.1+ */
       2                 :            : 
       3                 :            : #include "clean-ipc.h"
       4                 :            : #include "user-util.h"
       5                 :            : #include "tests.h"
       6                 :            : #include "util.h"
       7                 :            : 
       8                 :          0 : int main(int argc, char *argv[]) {
       9                 :            :         uid_t uid;
      10                 :            :         int r;
      11         [ #  # ]:          0 :         const char* name = argv[1] ?: NOBODY_USER_NAME;
      12                 :            : 
      13                 :          0 :         test_setup_logging(LOG_INFO);
      14                 :            : 
      15                 :          0 :         r = get_user_creds(&name, &uid, NULL, NULL, NULL, 0);
      16         [ #  # ]:          0 :         if (r == -ESRCH)
      17                 :          0 :                 return log_tests_skipped("Failed to resolve user");
      18         [ #  # ]:          0 :         if (r < 0) {
      19         [ #  # ]:          0 :                 log_error_errno(r, "Failed to resolve \"%s\": %m", name);
      20                 :          0 :                 return EXIT_FAILURE;
      21                 :            :         }
      22                 :            : 
      23                 :          0 :         r = clean_ipc_by_uid(uid);
      24                 :          0 :         return  r < 0 ? EXIT_FAILURE : EXIT_SUCCESS;
      25                 :            : }

Generated by: LCOV version 1.14