diff options
| author | Jon A. Cruz <jon@joncruz.org> | 2006-04-28 16:47:01 +0000 |
|---|---|---|
| committer | joncruz <joncruz@users.sourceforge.net> | 2006-04-28 16:47:01 +0000 |
| commit | 018fe5a60c309a2eebd42c3385401d1dc6ba8435 (patch) | |
| tree | 0e662200eaf1a5b33426927338f315ed8a0ca55f /src/dir-util-test.cpp | |
| parent | Adding unit test for verbs. (diff) | |
| download | inkscape-018fe5a60c309a2eebd42c3385401d1dc6ba8435.tar.gz inkscape-018fe5a60c309a2eebd42c3385401d1dc6ba8435.zip | |
Replaced two tests with CxxTest versions.
(bzr r605)
Diffstat (limited to 'src/dir-util-test.cpp')
| -rw-r--r-- | src/dir-util-test.cpp | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/src/dir-util-test.cpp b/src/dir-util-test.cpp deleted file mode 100644 index 691f6fee1..000000000 --- a/src/dir-util-test.cpp +++ /dev/null @@ -1,48 +0,0 @@ -#include "utest/test-2ary-cases.h" -#include "dir-util.h" -#include "streq.h" - -struct streq_functor { - bool operator()(char const *a, char const *b) - { - return streq(a, b); - } -}; - -static bool -test_sp_relative_path_from_path() -{ - utest_start("sp_relative_path_from_path"); - struct Case2<char const *, char const *, char const *> cases[] = { - {"/foo/bar", "/foo", "bar"}, - {"/foo/barney", "/foo/bar", "/foo/barney"}, - {"/foo/bar/baz", "/foo/", "bar/baz"}, - {"/foo/bar/baz", "/", "foo/bar/baz"}, - {"/foo/bar/baz", "/foo/qux", "/foo/bar/baz"}, - {"/foo", NULL, "/foo"} - }; - test_2ary_cases<char const *, char const *, char const *, char const *, streq_functor> - ("sp_relative_path_from_path", - sp_relative_path_from_path, - G_N_ELEMENTS(cases), cases); - return utest_end(); -} - -int main() -{ - return ( test_sp_relative_path_from_path() - ? EXIT_SUCCESS - : EXIT_FAILURE ); -} - - -/* - Local Variables: - mode:c++ - c-file-style:"stroustrup" - c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +)) - indent-tabs-mode:nil - fill-column:99 - End: -*/ -// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 : |
