Thomas Guyot-Sionnest
6e5d12b5d0
Use a more "natural" way of writing argument lists in extra-opts tests.
2009-06-11 00:14:23 -04:00
Thomas Guyot-Sionnest
ba132e9e52
Make extract_value more generic:
...
Add a separator argument passed using defines.
2009-01-26 02:05:21 -05:00
Thomas Guyot-Sionnest
0a74b6fda0
Remove the commented out blocks
...
The die tests are implemented in the test_*3.t files
2009-01-24 07:41:45 -05:00
Thomas Guyot-Sionnest
1b1dc7a48b
Fix paths in test_ini tests
2009-01-24 00:41:00 -05:00
Thomas Guyot-Sionnest
8b103c0c77
Add die tests for parse_ini
2009-01-23 02:43:59 -05:00
Thomas Guyot-Sionnest
485f306868
Return UNKNOWN if none of the default files can be found.
...
It makes no sense to return unknown if an implicit section is not found, but
go on if the file is missing
2009-01-22 02:24:39 -05:00
Thomas Guyot-Sionnest
bf4abd5395
Add die tests for extra-opts
2009-01-22 02:04:31 -05:00
Thomas Guyot-Sionnest
a4647be424
Move check_ntp's extract_value to utils_base.c.
...
This function can also be used to parse performance data strings which
could be useful in the future.
2009-01-21 01:27:40 -05:00
Thomas Guyot-Sionnest
81871eaa82
Accidentally included built executables - also updated .gitignore
2009-01-21 01:25:06 -05:00
Thomas Guyot-Sionnest
3b69f13467
Some platform are missing setenv
...
Instead of adding the gnulib module for solving tests only I split the test
in two, setting environment from Perl for the later.
2009-01-20 23:58:02 -05:00
Thomas Guyot-Sionnest
26bf63a5bb
Fix (or try at least) for IRIX compile to tap tests
...
Gnulib says: "$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise"
Everywhere else we use LTLIBINTL so I assume the tests should use it as well.
2009-01-20 22:28:30 -05:00
Thomas Guyot-Sionnest
82674792c7
Re-apply "Cleanup; fix the way libraries are linked; Make-It-Simple(tm)"
...
This reverts commit 7449b16b17 .
2009-01-18 16:26:58 -05:00
Thomas Guyot-Sionnest
09f9ddd18d
Typo
2009-01-15 06:12:04 -05:00
Thomas Guyot-Sionnest
f8c6d8b52e
Fix test from last commit
2009-01-09 08:16:52 -05:00
Thomas Guyot-Sionnest
4d5eb82a47
basename check in test_utils.c was accidentaly added again.
...
In 538b97c I reverted a serie of libtap patch by Ton Voon; it included
the removal of the useless basename check.
Relevant portion of the changelog from which it was removed (f31cd40 ):
Removed basename test as we should use base_name from GNUlib which is
tested separately
2009-01-09 02:44:36 -05:00
Thomas Guyot-Sionnest
7449b16b17
Revert "Cleanup; fix the way libraries are linked; Make-It-Simple(tm)"
...
Trying to see if this has any relation to the tinderbox failure. I doubt it
and will revert back as soon as it's tested.
This reverts commit a97e5fbda2 .
2009-01-09 02:27:02 -05:00
Thomas Guyot-Sionnest
254baca111
Try to make IRIX happy (this fixes a similar warning in Solaris)
2009-01-08 08:14:19 -05:00
Thomas Guyot-Sionnest
a97e5fbda2
Cleanup; fix the way libraries are linked; Make-It-Simple(tm)
...
lib/Makefile.am | 2 +-
lib/tests/Makefile.am | 37 ++++---------------------------------
2 files changed, 5 insertions(+), 34 deletions(-)
2009-01-07 04:41:54 -05:00
Thomas Guyot-Sionnest
2bbf2e6967
Add Libtap as a bundled library (does not change any behaviour without --enable-libtap)
...
Detects system library as pre-1.4.13 and does not install the built-in library anymore
Tested on:
- Linux x86_64, with and without local libtap (System libtap installed)
- Linux x86, with and without local libtap (System libtap NOT installed)
- Solaris SPARC, with and without local libtap, with and without system libtap installed
2008-11-29 04:38:54 -05:00
Thomas Guyot-Sionnest
538b97cea6
Revert inclusion of libtap into nagiosplugins
...
(except for the NEWS file)
This reverts the following commits (latest first): f3e0909 , 9f16b54 , be8df51 , f31cd40 , 5270c7d , a25083f , f1bfe40 , c503d85 and 6c476db
2008-11-28 03:22:39 -05:00
Thomas Guyot-Sionnest
6fbd14fea5
Removing CVS/SVN tags and replacing with git-based versioning
...
For contrib/, full tags have been imported from subversion
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2091 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-23 05:38:47 +00:00
Ton Voon
a688e9338a
Need to add in the libgnu.la for Solaris and other platforms
...
where missing functions have been replaced by GNUlib
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2071 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-05 17:07:40 +00:00
Thomas Guyot-Sionnest
3011838fe9
Fix calculation of extra-opts parameters.
...
By reading the current list instead of the additional one when counting parameters, extra-opts calculation was allocating insuficient space for the final array if later sections contained more arguments than the sum of all previously parsed sections.
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2069 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-05 16:15:59 +00:00
Thomas Guyot-Sionnest
cca36dc245
Fixed the test (not the bug yet) and added similar one to test_ini (that one works)
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2066 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-04 21:52:45 +00:00
Thomas Guyot-Sionnest
83ec9f2694
Corrected test_opts plan
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2065 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-04 21:31:10 +00:00
Thomas Guyot-Sionnest
5847c4eb83
Adding extra-opts check that crash on my prod servers (*** glibc detected *** malloc(): memory corruption: 0x0804e248 ***)
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2064 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-04 21:29:36 +00:00
Thomas Guyot-Sionnest
51ec51a8dc
Make extra-opts (C plugins) behave more like N::P:
...
N::P allows both '#' and ';' for comments. Extra-opts used to allow only '#', it now allows both (';' is the standard for ini files)
Extra-opts does not allow trailing comments anymore (like N::P)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2063 f882894a-f735-0410-b71e-b25c423dba1c
2008-11-04 17:41:53 +00:00
Ton Voon
f31cd40f7a
Correctly link to included libtap. Simplify invoking test scripts.
...
Removed basename test as we should use base_name from GNUlib which is
tested separately
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2042 f882894a-f735-0410-b71e-b25c423dba1c
2008-08-21 15:18:58 +00:00
Thomas Guyot-Sionnest
77362a18ba
Typos in comments
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2035 f882894a-f735-0410-b71e-b25c423dba1c
2008-08-21 04:17:25 +00:00
Ton Voon
f1bfe40afb
Use tap.h from the libtap directory
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2017 f882894a-f735-0410-b71e-b25c423dba1c
2008-07-02 20:07:00 +00:00
Ton Voon
6c476db6dc
Adding libtap into distribution to help run C based tests
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@2013 f882894a-f735-0410-b71e-b25c423dba1c
2008-06-26 22:00:08 +00:00
Thomas Guyot-Sionnest
2a4640f671
make parse_ini die like in N::P if section isn't found
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1976 f882894a-f735-0410-b71e-b25c423dba1c
2008-04-04 10:11:22 +00:00
Thomas Guyot-Sionnest
815fbd802f
Delete obsolete files
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1974 f882894a-f735-0410-b71e-b25c423dba1c
2008-04-02 09:19:26 +00:00
Thomas Guyot-Sionnest
0d13deb0e4
- Add --enable-extra-opts configure option for compiling extra-opts support
...
- Auto-update po/pot files
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1973 f882894a-f735-0410-b71e-b25c423dba1c
2008-04-02 09:11:44 +00:00
Thomas Guyot-Sionnest
d043862c15
Fix bug with --extra-opts as last argument with no value
...
Fix problem with duplicate function name (function should eventually move to /lib)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1969 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-31 07:04:07 +00:00
Thomas Guyot-Sionnest
20a8bf1a3f
Fix for last commit - I accidentaly broke my local Makefile and tests weren't being re-compiled.
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1968 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-31 05:31:14 +00:00
Thomas Guyot-Sionnest
8aa5ec317a
- Remove the last argument of np_extra_opts
...
- Code cleanups and comments
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1967 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-30 14:02:13 +00:00
Thomas Guyot-Sionnest
af71e9fc0e
write ini-file lookup function + tests
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1962 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-26 09:46:27 +00:00
Thomas Guyot-Sionnest
a34cf37404
Add extra-opts argument parsing with tests
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1961 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-24 07:02:28 +00:00
Thomas Guyot-Sionnest
4a7ff5e952
Add tests:
...
- DOS-newline ini file
- section defined twice
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1951 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-16 18:10:47 +00:00
Thomas Guyot-Sionnest
1a0ed0d6bb
- Make equal-less parameters illegal
...
- parameters without argument after '=' are now assumed to be argument-less
- Add a testcase for space in stanza and various argument-less parameters
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1948 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-15 20:47:43 +00:00
Thomas Guyot-Sionnest
ffab7ee68b
Fix segfault in test_ini.c and uncomment the affected tests
...
Fix bug in stanza parsing where full section could be skipped
Fix single-argument options
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1946 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-15 16:17:49 +00:00
Thomas Guyot-Sionnest
6004d95868
This commit consist of two changes:
...
1. Make np_get_defaults return a linked list instead of a string. It will then be easy to convert the linked list back to an argument array.
2. Fix tests 3-4 of test_ini.c.
A test_ini.t was added too. parse_ini and test_ini aren't included yet in the build makefiles.
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1945 f882894a-f735-0410-b71e-b25c423dba1c
2008-03-15 04:51:45 +00:00
Thomas Guyot-Sionnest
ec0ebf1108
Reverting patch to test 8-bit data: Still broken on Solaris (7-bit works as before)
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1927 f882894a-f735-0410-b71e-b25c423dba1c
2008-02-13 04:07:39 +00:00
Thomas Guyot-Sionnest
abbad00edd
Import Gnulib floorf and base64 and removed our old base64 library.
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1926 f882894a-f735-0410-b71e-b25c423dba1c
2008-02-12 12:03:58 +00:00
Thomas Guyot-Sionnest
a153e0b8f6
Bump lib/tests to GPLv3
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1914 f882894a-f735-0410-b71e-b25c423dba1c
2008-01-30 09:38:37 +00:00
Thomas Guyot-Sionnest
c51b6eea0e
Add a return-code check (also test cmd_run without out/err buffers)
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1905 f882894a-f735-0410-b71e-b25c423dba1c
2008-01-10 07:49:56 +00:00
Thomas Guyot-Sionnest
78def17d7c
Fix base64 test (known string wasn't null-terminated)
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1890 f882894a-f735-0410-b71e-b25c423dba1c
2008-01-06 15:44:57 +00:00
Thomas Guyot-Sionnest
541c4ef856
Fix tinderbox breakage
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1889 f882894a-f735-0410-b71e-b25c423dba1c
2008-01-06 07:04:10 +00:00
Ton Voon
151531173b
Run tinderbox builds in a test debug mode using "make test-debug"
...
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1866 f882894a-f735-0410-b71e-b25c423dba1c
2007-12-12 01:27:48 +00:00