import os
import sys
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..', '..', 'tests'))
from security_framework import SecurityTestFramework
config = {
'tool_name': 'ptx',
'bin_name': 'fptx',
'gnu_path': '/usr/bin/ptx',
'bss_size': 65536,
'max_binary_size': 102400,
'test_args': ['--help'],
'test_stdin': None,
'timeout': 10,
}
def tool_specific_tests(fw):
fw.log("\n=== 13. Tool-Specific: ptx ===")
rc, out, _ = fw.run_asm(["--help"])
fw.report_result(rc == 0 and len(out) > 50, f"ptx: --help (rc={rc})")
rc, out, _ = fw.run_asm(["--version"])
fw.report_result(rc == 0 and len(out) > 5, f"ptx: --version (rc={rc})")
if __name__ == '__main__':
fw = SecurityTestFramework(config)
fw.run_all(tool_specific_fn=tool_specific_tests)