wireshark/tools/pidl/tests/samba-ejs.pl

47 lines
1.6 KiB
Perl
Raw Normal View History

Update from samba tree revision 21471 to 21535 ============================ Samba log start ============ ------------------------------------------------------------------------ r21484 | jelmer | 2007-02-21 11:31:14 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Fix Needed* for nested datastructures. ------------------------------------------------------------------------ r21486 | jelmer | 2007-02-21 11:55:03 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm Remove spurious semicolons. ------------------------------------------------------------------------ r21487 | jelmer | 2007-02-21 12:32:48 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/librpc/idl/echo.idl M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm Fix warning when using anonymous types, initial work on nested type support in ejs. ------------------------------------------------------------------------ r21490 | jelmer | 2007-02-21 13:35:21 +0100 (Wed, 21 Feb 2007) | 3 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm A /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl Add some tests for the EJS code More work on supporting nested types in EJS. ------------------------------------------------------------------------ r21492 | jelmer | 2007-02-21 15:35:25 +0100 (Wed, 21 Feb 2007) | 2 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm Finish work on nested type support in EJS. ------------------------------------------------------------------------ r21493 | jelmer | 2007-02-21 21:59:01 +0100 (Wed, 21 Feb 2007) | 15 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm Patch from Ronnie Sahlberg. From his email: This patch changes the function name and signature that pidl generate a call for when dissecting a policy handle to a new, more PIDL-friendly function. It also stores the procedure name in a new pinfo-> field so that helpers that want to know the procedure name can finbd out easily. The new PIDL helper function for policy handles use this new field and will show OpenHKU(<...>) opened in frame X closed in frame Y for the policy handle. ------------------------------------------------------------------------ r21531 | jelmer | 2007-02-25 10:35:32 +0100 (Sun, 25 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm Use pidl-specific utility functions. Patch from Ronnie Sahlberg ------------------------------------------------------------------------ r21532 | jelmer | 2007-02-25 10:55:57 +0100 (Sun, 25 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add tests for StripPrefixes utility function. ------------------------------------------------------------------------ r21534 | jelmer | 2007-02-26 02:03:19 +0100 (Mon, 26 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add some more tests for wireshark. ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=20933
2007-02-26 08:57:03 +00:00
#!/usr/bin/perl
# (C) 2007 Jelmer Vernooij <jelmer@samba.org>
# Published under the GNU General Public License
use strict;
use warnings;
Update from samba tree revision 21565 to 21739 ============================ Samba log start ============ ------------------------------------------------------------------------ r21567 | jelmer | 2007-02-27 21:35:56 +0100 (Tue, 27 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add some more wireshark tests. ------------------------------------------------------------------------ r21568 | jelmer | 2007-02-27 22:37:31 +0100 (Tue, 27 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl More tests. ------------------------------------------------------------------------ r21572 | jelmer | 2007-02-28 00:47:07 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl M /branches/SAMBA_4_0/source/pidl/tests/ndr_tagtype.pl M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl More work towards supporting tagged types. ------------------------------------------------------------------------ r21573 | jelmer | 2007-02-28 01:19:57 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl Remove more code that assumed all types are typedefs. ------------------------------------------------------------------------ r21574 | jelmer | 2007-02-28 01:28:14 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl Fix handling of DECLARE. ------------------------------------------------------------------------ r21575 | jelmer | 2007-02-28 01:35:21 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl Fix handling of is_scalar() for declares. ------------------------------------------------------------------------ r21578 | jelmer | 2007-02-28 02:51:37 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/README M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr_tagtype.pl M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Use utility function for naming pull/push/print functions. ------------------------------------------------------------------------ r21579 | jelmer | 2007-02-28 03:01:58 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl Use utility function to determine function names in ejs code. ------------------------------------------------------------------------ r21584 | jelmer | 2007-02-28 14:25:53 +0100 (Wed, 28 Feb 2007) | 6 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/librpc/idl/echo.idl M /branches/SAMBA_4_0/source/pidl/README M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm M /branches/SAMBA_4_0/source/pidl/tests/header.pl M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl Support for tagged types has landed! It's now possible to use "struct foo" without a typedef in IDL files. echo_info4 is the first type that's been converted. ------------------------------------------------------------------------ r21586 | jelmer | 2007-02-28 15:56:46 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/MANIFEST update manifest ------------------------------------------------------------------------ r21654 | jelmer | 2007-03-02 15:05:52 +0100 (Fri, 02 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Add simple test for print functions. ------------------------------------------------------------------------ r21656 | jelmer | 2007-03-02 15:53:09 +0100 (Fri, 02 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 A /branches/SAMBA_4_0/source/lib/registry/tests A /branches/SAMBA_4_0/source/lib/registry/tests/generic.c (from /branches/SAMBA_4_0/source/torture/local/registry.c:21654) A /branches/SAMBA_4_0/source/lib/socket/testsuite.c (from /branches/SAMBA_4_0/source/torture/local/socket.c:21654) A /branches/SAMBA_4_0/source/lib/tdr/testsuite.c (from /branches/SAMBA_4_0/source/torture/local/tdr.c:21654) A /branches/SAMBA_4_0/source/lib/util/tests A /branches/SAMBA_4_0/source/lib/util/tests/file.c (from /branches/SAMBA_4_0/source/torture/local/util_file.c:21654) A /branches/SAMBA_4_0/source/lib/util/tests/idtree.c (from /branches/SAMBA_4_0/source/torture/local/idtree.c:21654) A /branches/SAMBA_4_0/source/lib/util/tests/strlist.c (from /branches/SAMBA_4_0/source/torture/local/util_strlist.c:21654) A /branches/SAMBA_4_0/source/librpc/tests A /branches/SAMBA_4_0/source/librpc/tests/binding_string.c (from /branches/SAMBA_4_0/source/torture/local/binding_string.c:21654) M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm D /branches/SAMBA_4_0/source/torture/local/binding_string.c M /branches/SAMBA_4_0/source/torture/local/config.mk D /branches/SAMBA_4_0/source/torture/local/idtree.c D /branches/SAMBA_4_0/source/torture/local/registry.c D /branches/SAMBA_4_0/source/torture/local/socket.c D /branches/SAMBA_4_0/source/torture/local/tdr.c D /branches/SAMBA_4_0/source/torture/local/util_file.c D /branches/SAMBA_4_0/source/torture/local/util_strlist.c Move tests a bit closer to the things they test, should make syncing with samba3 easier. ------------------------------------------------------------------------ r21681 | jelmer | 2007-03-04 15:16:52 +0100 (Sun, 04 Mar 2007) | 5 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/idl.yp M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/IDL.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/header.pl M /branches/SAMBA_4_0/source/pidl/tests/parse_idl.pl Fix bug in the parsing code that parsed "struct foo;" the same as "struct foo {};". Reported by one of the OpenChange folks, thanks! ------------------------------------------------------------------------ r21682 | jelmer | 2007-03-04 15:31:18 +0100 (Sun, 04 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm Remove accidently committed debug command. ------------------------------------------------------------------------ r21690 | jelmer | 2007-03-05 01:03:44 +0100 (Mon, 05 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/tests/header.pl M /branches/SAMBA_4_0/source/pidl/tests/parse_idl.pl Test use of typedef /and/ struct name ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=20992
2007-03-07 07:55:00 +00:00
use Test::More tests => 17;
Update from samba tree revision 21471 to 21535 ============================ Samba log start ============ ------------------------------------------------------------------------ r21484 | jelmer | 2007-02-21 11:31:14 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Fix Needed* for nested datastructures. ------------------------------------------------------------------------ r21486 | jelmer | 2007-02-21 11:55:03 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm Remove spurious semicolons. ------------------------------------------------------------------------ r21487 | jelmer | 2007-02-21 12:32:48 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/librpc/idl/echo.idl M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm Fix warning when using anonymous types, initial work on nested type support in ejs. ------------------------------------------------------------------------ r21490 | jelmer | 2007-02-21 13:35:21 +0100 (Wed, 21 Feb 2007) | 3 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm A /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl Add some tests for the EJS code More work on supporting nested types in EJS. ------------------------------------------------------------------------ r21492 | jelmer | 2007-02-21 15:35:25 +0100 (Wed, 21 Feb 2007) | 2 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm Finish work on nested type support in EJS. ------------------------------------------------------------------------ r21493 | jelmer | 2007-02-21 21:59:01 +0100 (Wed, 21 Feb 2007) | 15 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm Patch from Ronnie Sahlberg. From his email: This patch changes the function name and signature that pidl generate a call for when dissecting a policy handle to a new, more PIDL-friendly function. It also stores the procedure name in a new pinfo-> field so that helpers that want to know the procedure name can finbd out easily. The new PIDL helper function for policy handles use this new field and will show OpenHKU(<...>) opened in frame X closed in frame Y for the policy handle. ------------------------------------------------------------------------ r21531 | jelmer | 2007-02-25 10:35:32 +0100 (Sun, 25 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm Use pidl-specific utility functions. Patch from Ronnie Sahlberg ------------------------------------------------------------------------ r21532 | jelmer | 2007-02-25 10:55:57 +0100 (Sun, 25 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add tests for StripPrefixes utility function. ------------------------------------------------------------------------ r21534 | jelmer | 2007-02-26 02:03:19 +0100 (Mon, 26 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add some more tests for wireshark. ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=20933
2007-02-26 08:57:03 +00:00
use FindBin qw($RealBin);
use lib "$RealBin";
use Util;
use Parse::Pidl::Util qw(MyDumper);
use Parse::Pidl::Samba4::EJS qw(get_pointer_to get_value_of check_null_pointer
Note: make test for the following update generates 1 error: --------- tests/header..............NOK 14# Failed test 'struct declaration' # in tests/header.pl at line 49. # '/* header auto-generated by pidl */ # # #include <core.h> # #include <stdint.h> # # #ifndef _HEADER_p # #define _HEADER_p # # struct x#endif /* _HEADER_p */ # ' # doesn't match '(?ms-xi:struct x;)' # Looks like you failed 1 test of 15. tests/header..............dubious Test returned status 1 (wstat 256, 0x100) DIED. FAILED test 14 --------- Update from samba tree revision 22314 to 22657 ============================ Samba log start ============ ------------------------------------------------------------------------ r22357 | jelmer | 2007-04-19 03:26:15 +0200 (Thu, 19 Apr 2007) | 2 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba3/ClientNDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/TDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Don't use 'our' ------------------------------------------------------------------------ r22453 | jelmer | 2007-04-22 12:42:33 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/TDR.pm M /branches/SAMBA_4_0/source/pidl/tests/tdr.pl Fix TDR testsuite without using our. ------------------------------------------------------------------------ r22456 | jelmer | 2007-04-22 15:57:07 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/pidl M /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Merge wireshark and ejs test improvements. ------------------------------------------------------------------------ r22457 | jelmer | 2007-04-22 16:19:22 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba3/ClientNDR.pm M /branches/SAMBA_4_0/source/pidl/pidl M /branches/SAMBA_4_0/source/pidl/tests/samba3-cli.pl Fix tests for Samba3 client generator. ------------------------------------------------------------------------ r22462 | jelmer | 2007-04-22 17:59:34 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/pidl M /branches/SAMBA_4_0/source/pidl/tests/Util.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Fix test suite for ndr parser without using 'our' ------------------------------------------------------------------------ r22520 | jelmer | 2007-04-25 18:10:54 +0200 (Wed, 25 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-conf.pl Fix the TYPE command. ------------------------------------------------------------------------ r22617 | metze | 2007-05-01 03:57:17 +0200 (Tue, 01 May 2007) | 4 lines Changed paths: M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm assume we have defered elements if the type is just provides via 'declare' this should fix the problem with the winbind IRPC calls metze ------------------------------------------------------------------------ r22618 | metze | 2007-05-01 04:00:57 +0200 (Tue, 01 May 2007) | 8 lines Changed paths: M /branches/SAMBA_4_0/source/pidl/idl.yp M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/IDL.pm handle the properties related to the type and not to 'declare' to avoid a pidl warning with: declare [switch_type(uint16)] union netr_Validation; void foo([in] uint16 level, [in,switch_is(level)] netrValidation info); metze ------------------------------------------------------------------------ r22640 | metze | 2007-05-02 20:00:02 +0200 (Wed, 02 May 2007) | 4 lines Changed paths: M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm - generate nicer output - fix compiler warning about unused ';' metze ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=21671
2007-05-03 21:56:22 +00:00
fn_declare TypeFunctionName);
Update from samba tree revision 21471 to 21535 ============================ Samba log start ============ ------------------------------------------------------------------------ r21484 | jelmer | 2007-02-21 11:31:14 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Fix Needed* for nested datastructures. ------------------------------------------------------------------------ r21486 | jelmer | 2007-02-21 11:55:03 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm Remove spurious semicolons. ------------------------------------------------------------------------ r21487 | jelmer | 2007-02-21 12:32:48 +0100 (Wed, 21 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/librpc/idl/echo.idl M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm Fix warning when using anonymous types, initial work on nested type support in ejs. ------------------------------------------------------------------------ r21490 | jelmer | 2007-02-21 13:35:21 +0100 (Wed, 21 Feb 2007) | 3 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm A /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl Add some tests for the EJS code More work on supporting nested types in EJS. ------------------------------------------------------------------------ r21492 | jelmer | 2007-02-21 15:35:25 +0100 (Wed, 21 Feb 2007) | 2 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm Finish work on nested type support in EJS. ------------------------------------------------------------------------ r21493 | jelmer | 2007-02-21 21:59:01 +0100 (Wed, 21 Feb 2007) | 15 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm Patch from Ronnie Sahlberg. From his email: This patch changes the function name and signature that pidl generate a call for when dissecting a policy handle to a new, more PIDL-friendly function. It also stores the procedure name in a new pinfo-> field so that helpers that want to know the procedure name can finbd out easily. The new PIDL helper function for policy handles use this new field and will show OpenHKU(<...>) opened in frame X closed in frame Y for the policy handle. ------------------------------------------------------------------------ r21531 | jelmer | 2007-02-25 10:35:32 +0100 (Sun, 25 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm Use pidl-specific utility functions. Patch from Ronnie Sahlberg ------------------------------------------------------------------------ r21532 | jelmer | 2007-02-25 10:55:57 +0100 (Sun, 25 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add tests for StripPrefixes utility function. ------------------------------------------------------------------------ r21534 | jelmer | 2007-02-26 02:03:19 +0100 (Mon, 26 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add some more tests for wireshark. ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=20933
2007-02-26 08:57:03 +00:00
is("&foo", get_pointer_to("foo"));
is("&(&foo)", get_pointer_to(get_pointer_to("foo")));
is("*foo", get_pointer_to("**foo"));
is("foo", get_pointer_to("*foo"));
is("foo", get_value_of("&foo"));
is("*foo", get_value_of("foo"));
is("**foo", get_value_of("*foo"));
Note: make test for the following update generates 1 error: --------- tests/header..............NOK 14# Failed test 'struct declaration' # in tests/header.pl at line 49. # '/* header auto-generated by pidl */ # # #include <core.h> # #include <stdint.h> # # #ifndef _HEADER_p # #define _HEADER_p # # struct x#endif /* _HEADER_p */ # ' # doesn't match '(?ms-xi:struct x;)' # Looks like you failed 1 test of 15. tests/header..............dubious Test returned status 1 (wstat 256, 0x100) DIED. FAILED test 14 --------- Update from samba tree revision 22314 to 22657 ============================ Samba log start ============ ------------------------------------------------------------------------ r22357 | jelmer | 2007-04-19 03:26:15 +0200 (Thu, 19 Apr 2007) | 2 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba3/ClientNDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/TDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Don't use 'our' ------------------------------------------------------------------------ r22453 | jelmer | 2007-04-22 12:42:33 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/TDR.pm M /branches/SAMBA_4_0/source/pidl/tests/tdr.pl Fix TDR testsuite without using our. ------------------------------------------------------------------------ r22456 | jelmer | 2007-04-22 15:57:07 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/pidl M /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Merge wireshark and ejs test improvements. ------------------------------------------------------------------------ r22457 | jelmer | 2007-04-22 16:19:22 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba3/ClientNDR.pm M /branches/SAMBA_4_0/source/pidl/pidl M /branches/SAMBA_4_0/source/pidl/tests/samba3-cli.pl Fix tests for Samba3 client generator. ------------------------------------------------------------------------ r22462 | jelmer | 2007-04-22 17:59:34 +0200 (Sun, 22 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/pidl M /branches/SAMBA_4_0/source/pidl/tests/Util.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Fix test suite for ndr parser without using 'our' ------------------------------------------------------------------------ r22520 | jelmer | 2007-04-25 18:10:54 +0200 (Wed, 25 Apr 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-conf.pl Fix the TYPE command. ------------------------------------------------------------------------ r22617 | metze | 2007-05-01 03:57:17 +0200 (Tue, 01 May 2007) | 4 lines Changed paths: M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm assume we have defered elements if the type is just provides via 'declare' this should fix the problem with the winbind IRPC calls metze ------------------------------------------------------------------------ r22618 | metze | 2007-05-01 04:00:57 +0200 (Tue, 01 May 2007) | 8 lines Changed paths: M /branches/SAMBA_4_0/source/pidl/idl.yp M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/IDL.pm handle the properties related to the type and not to 'declare' to avoid a pidl warning with: declare [switch_type(uint16)] union netr_Validation; void foo([in] uint16 level, [in,switch_is(level)] netrValidation info); metze ------------------------------------------------------------------------ r22640 | metze | 2007-05-02 20:00:02 +0200 (Wed, 02 May 2007) | 4 lines Changed paths: M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm - generate nicer output - fix compiler warning about unused ';' metze ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=21671
2007-05-03 21:56:22 +00:00
my $ejs = new Parse::Pidl::Samba4::EJS();
$ejs->check_null_pointer("bla");
is($ejs->{res}, "");
$ejs = new Parse::Pidl::Samba4::EJS();
$ejs->check_null_pointer("*bla");
is($ejs->{res}, "if (bla == NULL) return NT_STATUS_INVALID_PARAMETER_MIX;\n");
$ejs = new Parse::Pidl::Samba4::EJS();
$ejs->fn_declare({ PROPERTIES => { public => 1 } }, "myproto(int x)");
is($ejs->{res}, "_PUBLIC_ myproto(int x)\n");
is($ejs->{res_hdr}, "myproto(int x);\n");
$ejs = new Parse::Pidl::Samba4::EJS();
$ejs->fn_declare({ PROPERTIES => {} }, "mybla(int foo)");
is($ejs->{res}, "static mybla(int foo)\n");
is($ejs->{res_hdr}, "");
Update from samba tree revision 21565 to 21739 ============================ Samba log start ============ ------------------------------------------------------------------------ r21567 | jelmer | 2007-02-27 21:35:56 +0100 (Tue, 27 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl Add some more wireshark tests. ------------------------------------------------------------------------ r21568 | jelmer | 2007-02-27 22:37:31 +0100 (Tue, 27 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Wireshark/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/wireshark-ndr.pl More tests. ------------------------------------------------------------------------ r21572 | jelmer | 2007-02-28 00:47:07 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl M /branches/SAMBA_4_0/source/pidl/tests/ndr_tagtype.pl M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl More work towards supporting tagged types. ------------------------------------------------------------------------ r21573 | jelmer | 2007-02-28 01:19:57 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl Remove more code that assumed all types are typedefs. ------------------------------------------------------------------------ r21574 | jelmer | 2007-02-28 01:28:14 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl Fix handling of DECLARE. ------------------------------------------------------------------------ r21575 | jelmer | 2007-02-28 01:35:21 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Typelist.pm M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl Fix handling of is_scalar() for declares. ------------------------------------------------------------------------ r21578 | jelmer | 2007-02-28 02:51:37 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/README M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/ndr_tagtype.pl M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Use utility function for naming pull/push/print functions. ------------------------------------------------------------------------ r21579 | jelmer | 2007-02-28 03:01:58 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ejs.pl Use utility function to determine function names in ejs code. ------------------------------------------------------------------------ r21584 | jelmer | 2007-02-28 14:25:53 +0100 (Wed, 28 Feb 2007) | 6 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/librpc/idl/echo.idl M /branches/SAMBA_4_0/source/pidl/README M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/EJS.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/Header.pm M /branches/SAMBA_4_0/source/pidl/tests/header.pl M /branches/SAMBA_4_0/source/pidl/tests/ndr.pl M /branches/SAMBA_4_0/source/pidl/tests/typelist.pl Support for tagged types has landed! It's now possible to use "struct foo" without a typedef in IDL files. echo_info4 is the first type that's been converted. ------------------------------------------------------------------------ r21586 | jelmer | 2007-02-28 15:56:46 +0100 (Wed, 28 Feb 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/MANIFEST update manifest ------------------------------------------------------------------------ r21654 | jelmer | 2007-03-02 15:05:52 +0100 (Fri, 02 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm M /branches/SAMBA_4_0/source/pidl/tests/samba-ndr.pl Add simple test for print functions. ------------------------------------------------------------------------ r21656 | jelmer | 2007-03-02 15:53:09 +0100 (Fri, 02 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 A /branches/SAMBA_4_0/source/lib/registry/tests A /branches/SAMBA_4_0/source/lib/registry/tests/generic.c (from /branches/SAMBA_4_0/source/torture/local/registry.c:21654) A /branches/SAMBA_4_0/source/lib/socket/testsuite.c (from /branches/SAMBA_4_0/source/torture/local/socket.c:21654) A /branches/SAMBA_4_0/source/lib/tdr/testsuite.c (from /branches/SAMBA_4_0/source/torture/local/tdr.c:21654) A /branches/SAMBA_4_0/source/lib/util/tests A /branches/SAMBA_4_0/source/lib/util/tests/file.c (from /branches/SAMBA_4_0/source/torture/local/util_file.c:21654) A /branches/SAMBA_4_0/source/lib/util/tests/idtree.c (from /branches/SAMBA_4_0/source/torture/local/idtree.c:21654) A /branches/SAMBA_4_0/source/lib/util/tests/strlist.c (from /branches/SAMBA_4_0/source/torture/local/util_strlist.c:21654) A /branches/SAMBA_4_0/source/librpc/tests A /branches/SAMBA_4_0/source/librpc/tests/binding_string.c (from /branches/SAMBA_4_0/source/torture/local/binding_string.c:21654) M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm D /branches/SAMBA_4_0/source/torture/local/binding_string.c M /branches/SAMBA_4_0/source/torture/local/config.mk D /branches/SAMBA_4_0/source/torture/local/idtree.c D /branches/SAMBA_4_0/source/torture/local/registry.c D /branches/SAMBA_4_0/source/torture/local/socket.c D /branches/SAMBA_4_0/source/torture/local/tdr.c D /branches/SAMBA_4_0/source/torture/local/util_file.c D /branches/SAMBA_4_0/source/torture/local/util_strlist.c Move tests a bit closer to the things they test, should make syncing with samba3 easier. ------------------------------------------------------------------------ r21681 | jelmer | 2007-03-04 15:16:52 +0100 (Sun, 04 Mar 2007) | 5 lines Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/TODO M /branches/SAMBA_4_0/source/pidl/idl.yp M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/IDL.pm M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm M /branches/SAMBA_4_0/source/pidl/tests/header.pl M /branches/SAMBA_4_0/source/pidl/tests/parse_idl.pl Fix bug in the parsing code that parsed "struct foo;" the same as "struct foo {};". Reported by one of the OpenChange folks, thanks! ------------------------------------------------------------------------ r21682 | jelmer | 2007-03-04 15:31:18 +0100 (Sun, 04 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm Remove accidently committed debug command. ------------------------------------------------------------------------ r21690 | jelmer | 2007-03-05 01:03:44 +0100 (Mon, 05 Mar 2007) | 1 line Changed paths: M /branches/SAMBA_4_0 M /branches/SAMBA_4_0/source/pidl/tests/header.pl M /branches/SAMBA_4_0/source/pidl/tests/parse_idl.pl Test use of typedef /and/ struct name ------------------------------------------------------------------------ ------------------------------------------------------------------------ ============================ Samba log end ============== svn path=/trunk/; revision=20992
2007-03-07 07:55:00 +00:00
is(TypeFunctionName("ejs_pull", "uint32"), "ejs_pull_uint32");
is(TypeFunctionName("ejs_pull", {TYPE => "ENUM", NAME => "bar"}), "ejs_pull_ENUM_bar");
is(TypeFunctionName("ejs_pull", {TYPE => "TYPEDEF", NAME => "bar", DATA => undef}), "ejs_pull_bar");
is(TypeFunctionName("ejs_push", {TYPE => "STRUCT", NAME => "bar"}), "ejs_push_STRUCT_bar");