xref: /llvm-project/llvm/utils/lit/tests/shtest-format-argv0.py (revision 2f69c82cec1ae05b4fdcef4ac48f48e9e2bad32b)
1af8aee7cSShuhong Liu# Check that we route argv[0] as it was written, instead of the resolved
2af8aee7cSShuhong Liu# path. This is important for some tools, in particular '[' which at least on OS
3af8aee7cSShuhong Liu# X only recognizes that it is in '['-mode when its argv[0] is exactly
4af8aee7cSShuhong Liu# '['. Otherwise it will refuse to accept the trailing closing bracket.
5af8aee7cSShuhong Liu#
6af8aee7cSShuhong Liu# This test is not supported on AIX since `[` is only available as a shell builtin
7af8aee7cSShuhong Liu# and is not installed under PATH by default.
82402f938SShuhong Liu# UNSUPPORTED: system-aix
9af8aee7cSShuhong Liu#
10*2f69c82cSMichał Górny# RUN: %{lit} -v %{inputs}/shtest-format-argv0 | FileCheck %s
11af8aee7cSShuhong Liu
12af8aee7cSShuhong Liu# CHECK: -- Testing:
13af8aee7cSShuhong Liu# CHECK: PASS: shtest-format-argv0 :: argv0.txt
14