From 6155908c0e8b622c8ce9ea356e3d249e3c2e61c1 Mon Sep 17 00:00:00 2001 From: Mohamed Barwani Date: Mon, 13 Aug 2007 15:55:13 +0000 Subject: [PATCH] make sure the test shows any garbage output. Merge of master-melb:xfs-cmds:29378a by kenmcd. Add the modified filter that was removed from common.dmapi --- 168 | 23 +++++++++++++++++++++++ 168.out | 4 ++-- common.dmapi | 24 ------------------------ 3 files changed, 25 insertions(+), 26 deletions(-) diff --git a/168 b/168 index 2c105ef9..5a233585 100755 --- a/168 +++ b/168 @@ -25,6 +25,29 @@ _cleanup() _cleanup_testdir } +_filter_dmapi_print_event() { + $PERL_PROG -ne ' +# replace session/file specific output with generic placeholders +s/token\s+\d+/token TOKEN/g ; +s/sequence\s+\d+/sequence SEQ/g ; +s/^\s+parent\s+dir\s+\w+/parent dir PARENT_DIR/g ; +s/^\s+name\s+.*/name FILE_NAME/g ; +s/^\s+mode\s+bits\s+mode\s+\d+:\s+/mode bits mode MODE: /g ; +s/perm\s+[\w|-]+\s[\w|-]+\s[\w|-]+/perm PERMISSIONS/g ; +s/,\s+type\s+.*/, type FILE_TYPE/g ; +s/^\s+object\s+\w+/object OBJECT/g ; +s/^\s+new\s+object\s+\w+/new object OBJECT/g ; +s/^\s+handle\s+\w+/handle HANDLE/g ; + +# when print_event is killed, the following is output. trim it +s/^\s*print_event: Processing any undelivered event messages.*\n//g ; +s/^\s*print_event: Shutting down the session.*\n//g ; + +# trim blank lines +s/^\s*\n//g ; + print ;' +} + # get standard environment, filters and checks . ./common.rc . ./common.filter diff --git a/168.out b/168.out index 8727d7ba..d46d99c1 100644 --- a/168.out +++ b/168.out @@ -5,16 +5,16 @@ QA output created by 168 # set dmapi attributes on file # remove file # here comes the dmapi print_event filtered and sorted output + attrcopy 415454525f56414c55455f3100 attrcopy attrname + attrname ATTR_NAM retcode 0 retcode 0 retcode 0 retcode 0 -attrcopy COPY attribute: token TOKEN sequence SEQ attribute: token TOKEN sequence SEQ -attrname NAME create: token TOKEN sequence SEQ create: token TOKEN sequence SEQ destroy: token TOKEN sequence SEQ diff --git a/common.dmapi b/common.dmapi index 1873fbbd..f71497a6 100644 --- a/common.dmapi +++ b/common.dmapi @@ -29,28 +29,4 @@ _dmapi_scratch_mount () { fi } -_filter_dmapi_print_event() { - $PERL_PROG -ne ' -# replace session/file specific output with generic placeholders -s/token\s+\d+/token TOKEN/g ; -s/sequence\s+\d+/sequence SEQ/g ; -s/^\s+parent\s+dir\s+\w+/parent dir PARENT_DIR/g ; -s/^\s+name\s+.*/name FILE_NAME/g ; -s/^\s+mode\s+bits\s+mode\s+\d+:\s+/mode bits mode MODE: /g ; -s/perm\s+[\w|-]+\s[\w|-]+\s[\w|-]+/perm PERMISSIONS/g ; -s/,\s+type\s+.*/, type FILE_TYPE/g ; -s/^\s+object\s+\w+/object OBJECT/g ; -s/^\s+new\s+object\s+\w+/new object OBJECT/g ; -s/^\s+handle\s+\w+/handle HANDLE/g ; -s/^\s+attrcopy\s+\w+/attrcopy COPY/g ; -s/^\s+attrname\s+\w+/attrname NAME/g ; - -# when print_event is killed, the following is output. trim it -s/^\s*print_event: Processing any undelivered event messages.*\n//g ; -s/^\s*print_event: Shutting down the session.*\n//g ; - -# trim blank lines -s/^\s*\n//g ; - print ;' -} -- 2.39.5