[asterisk-bugs] [JIRA] (ASTERISK-24292) Asterisk testsuite - Files that should (or not) be executable
Matt Jordan (JIRA)
noreply at issues.asterisk.org
Wed Sep 3 11:04:29 CDT 2014
[ https://issues.asterisk.org/jira/browse/ASTERISK-24292?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=222533#comment-222533 ]
Matt Jordan commented on ASTERISK-24292:
----------------------------------------
Tzafrir - do you have a patch that fixes the above mentioned issues?
> Asterisk testsuite - Files that should (or not) be executable
> -------------------------------------------------------------
>
> Key: ASTERISK-24292
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-24292
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: Tests/General
> Reporter: Tzafrir Cohen
>
> This is a minor issue I encountered while packaging the asterisk test
> suite.
> Lintian, the Debian packaging checker, (mostly rightly) complained about
> some files that were executable and should not have been and vice versa.
> Here is what I needed to do to override most of the warnings:
> Below, using Makefile syntax. The testsuite files were installed under
> $(target).
> {noformat}
> find $(target)/tests -name \*.py -executable | \
> while read file; do \
> if head -q -n1 $$file | egrep -q "^('''|\"\"\")"; then \
> chmod a-x $$file; \
> fi; \
> done
> find $(target)/tests/channels/SIP/rfc2833_dtmf_detect \
> -name \*.xml -exec chmod a-x \{\} \;
> {noformat}
> So I removed the executable bits from some XML files and from some
> (actually many) python files that had <'''> or <"""> in the first line.
> Those are surely not executable (#!).This is a minor issue I encountered while packaging the asterisk test
> suite.
> Lintian, the Debian packaging checker, (mostly rightly) complained about
> some files that were executable and should not have been and vice versa.
> Here is what I needed to do to override most of the warnings:
> Below, using Makefile syntax. The testsuite files were installed under
> $(target).
> {noformat}
> find $(target)/tests -name \*.py -executable | \
> while read file; do \
> if head -q -n1 $$file | egrep -q "^('''|\"\"\")"; then \
> chmod a-x $$file; \
> fi; \
> done
> find $(target)/tests/channels/SIP/rfc2833_dtmf_detect \
> -name \*.xml -exec chmod a-x \{\} \;
> {noformat}
> So I removed the executable bits from some XML files and from some
> (actually many) python files that had <'''> or <"""> in the first line.
> Those are surely not executable (#!).This is a minor issue I encountered while packaging the asterisk test
> suite.
> Lintian, the Debian packaging checker, (mostly rightly) complained about
> some files that were executable and should not have been and vice versa.
> Here is what I needed to do to override most of the warnings:
> Below, using Makefile syntax. The testsuite files were installed under
> $(target).
> {noformat}
> find $(target)/tests -name \*.py -executable | \
> while read file; do \
> if head -q -n1 $$file | egrep -q "^('''|\"\"\")"; then \
> chmod a-x $$file; \
> fi; \
> done
> find $(target)/tests/channels/SIP/rfc2833_dtmf_detect \
> -name \*.xml -exec chmod a-x \{\} \;
> {noformat}
> So I removed the executable bits from some XML files and from some
> (actually many) python files that had <'''> or <"""> in the first line.
> Those are surely not executable (#!).This is a minor issue I encountered while packaging the asterisk test
> suite.
> Lintian, the Debian packaging checker, (mostly rightly) complained about
> some files that were executable and should not have been and vice versa.
> Here is what I needed to do to override most of the warnings:
> Below, using Makefile syntax. The testsuite files were installed under
> $(target).
> {noformat}
> find $(target)/tests -name \*.py -executable | \
> while read file; do \
> if head -q -n1 $$file | egrep -q "^('''|\"\"\")"; then \
> chmod a-x $$file; \
> fi; \
> done
> find $(target)/tests/channels/SIP/rfc2833_dtmf_detect \
> -name \*.xml -exec chmod a-x \{\} \;
> {noformat}
> So I removed the executable bits from some XML files and from some
> (actually many) python files that had <'''> or <"""> in the first line.
> Those are surely not executable (#!).
> Left over warnings:
> {noformat}
> W: asterisk-testsuite: script-not-executable usr/share/asterisk-testsuite/lib/sh/library.sh
> W: asterisk-testsuite: script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/donothing.agi
> W: asterisk-testsuite: script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/executing.agi
> W: asterisk-testsuite: script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/waiting.agi
> W: asterisk-testsuite: script-not-executable usr/share/asterisk-testsuite/tests/skeleton_test/run-test
> {noformat}
> library.sh surely should not need a script header (and if you just give
> it a header for identification: #!/bin/sh is better). Not sure if the
> AGIs are intentionally not executable.
> For the record, I suppressed the following:
> # For tests that check bad interpreters:
> {noformat}
> unusual-interpreter usr/share/asterisk-testsuite/tests/agi/exit_status/badinterpreter.agi #!/bin/this-path-does-not-exist
> script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/badinterpreter2.agi
> wrong-path-for-interpreter usr/share/asterisk-testsuite/tests/agi/exit_status/badinterpreter3.agi (#!/tmp/bash != /bin/bash)
> script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/badinterpreter.agi
> unusual-interpreter usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/badinterpreter.agi #!/bin/this-path-does-not-exist
> script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/badinterpreter2.agi
> script-not-executable usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/badinterpreter3.agi
> wrong-path-for-interpreter usr/share/asterisk-testsuite/tests/agi/exit_status/userA/agi-bin/badinterpreter3.agi (#!/tmp/bash != /bin/bash)
> {noformat}
--
This message was sent by Atlassian JIRA
(v6.2#6252)
More information about the asterisk-bugs
mailing list