Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
polkit
polkit
Commits
bcff1bde
Commit
bcff1bde
authored
Nov 11, 2007
by
David Zeuthen
Browse files
add (empty, for now) tests for remaining files
parent
c372969e
Changes
5
Hide whitespace changes
Inline
Side-by-side
src/polkit/polkit-config.c
View file @
bcff1bde
...
...
@@ -47,6 +47,7 @@
#include
"polkit-debug.h"
#include
"polkit-error.h"
#include
"polkit-private.h"
#include
"polkit-test.h"
/**
* SECTION:polkit-config
...
...
@@ -771,3 +772,19 @@ polkit_config_determine_admin_auth_type (PolKitConfig *pk_config,
}
}
#ifdef POLKIT_BUILD_TESTS
static
polkit_bool_t
_run_test
(
void
)
{
return
TRUE
;
}
PolKitTest
_test_config
=
{
"polkit_config"
,
NULL
,
NULL
,
_run_test
};
#endif
/* POLKIT_BUILD_TESTS */
src/polkit/polkit-context.c
View file @
bcff1bde
...
...
@@ -44,6 +44,7 @@
#include
"polkit-context.h"
#include
"polkit-policy-cache.h"
#include
"polkit-private.h"
#include
"polkit-test.h"
/**
* SECTION:polkit
...
...
@@ -801,3 +802,20 @@ polkit_context_get_authorization_db (PolKitContext *pk_context)
{
return
pk_context
->
authdb
;
}
#ifdef POLKIT_BUILD_TESTS
static
polkit_bool_t
_run_test
(
void
)
{
return
TRUE
;
}
PolKitTest
_test_context
=
{
"polkit_context"
,
NULL
,
NULL
,
_run_test
};
#endif
/* POLKIT_BUILD_TESTS */
src/polkit/polkit-sysdeps.c
View file @
bcff1bde
...
...
@@ -40,7 +40,7 @@
#include
"polkit-sysdeps.h"
#include
"polkit-private.h"
#include
"polkit-test.h"
/**
* SECTION:polkit-sysdeps
...
...
@@ -159,3 +159,20 @@ polkit_sysdeps_get_exe_for_pid (pid_t pid, char *out_buf, size_t buf_size)
out:
return
ret
;
}
#ifdef POLKIT_BUILD_TESTS
static
polkit_bool_t
_run_test
(
void
)
{
return
TRUE
;
}
PolKitTest
_test_sysdeps
=
{
"polkit_sysdeps"
,
NULL
,
NULL
,
_run_test
};
#endif
/* POLKIT_BUILD_TESTS */
src/polkit/polkit-test.c
View file @
bcff1bde
...
...
@@ -52,6 +52,9 @@ static PolKitTest *tests[] = {
&
_test_authorization_constraint
,
&
_test_authorization
,
&
_test_authorization_db
,
&
_test_config
,
&
_test_sysdeps
,
&
_test_context
,
};
int
...
...
src/polkit/polkit-test.h
View file @
bcff1bde
...
...
@@ -63,6 +63,9 @@ extern PolKitTest _test_policy_cache;
extern
PolKitTest
_test_authorization_constraint
;
extern
PolKitTest
_test_authorization
;
extern
PolKitTest
_test_authorization_db
;
extern
PolKitTest
_test_config
;
extern
PolKitTest
_test_sysdeps
;
extern
PolKitTest
_test_context
;
POLKIT_END_DECLS
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment