diff options
Diffstat (limited to 'test.c')
-rw-r--r-- | test.c | 20 |
1 files changed, 11 insertions, 9 deletions
@@ -178,6 +178,15 @@ static int test_eaccess(); | |||
178 | static int is_a_group_member(); | 178 | static int is_a_group_member(); |
179 | static void initialize_group_array(); | 179 | static void initialize_group_array(); |
180 | 180 | ||
181 | const char test_usage[] = | ||
182 | "test EXPRESSION\n" | ||
183 | "or [ EXPRESSION ]\n" | ||
184 | #ifndef BB_FEATURE_TRIVIAL_HELP | ||
185 | "\nChecks file types and compares values returning an exit\n" | ||
186 | "code determined by the value of EXPRESSION.\n" | ||
187 | #endif | ||
188 | ; | ||
189 | |||
181 | extern int | 190 | extern int |
182 | test_main(int argc, char** argv) | 191 | test_main(int argc, char** argv) |
183 | { | 192 | { |
@@ -188,15 +197,8 @@ test_main(int argc, char** argv) | |||
188 | fatalError("missing ]\n"); | 197 | fatalError("missing ]\n"); |
189 | argv[argc] = NULL; | 198 | argv[argc] = NULL; |
190 | } | 199 | } |
191 | if (strcmp(argv[1], dash_dash_help) == 0) { | 200 | if (strcmp(argv[1], dash_dash_help) == 0) |
192 | usage("test EXPRESSION\n" | 201 | usage(test_usage); |
193 | "or [ EXPRESSION ]\n" | ||
194 | #ifndef BB_FEATURE_TRIVIAL_HELP | ||
195 | "\nChecks file types and compares values returning an exit\n" | ||
196 | "code determined by the value of EXPRESSION.\n" | ||
197 | #endif | ||
198 | ); | ||
199 | } | ||
200 | 202 | ||
201 | /* Implement special cases from POSIX.2, section 4.62.4 */ | 203 | /* Implement special cases from POSIX.2, section 4.62.4 */ |
202 | switch (argc) { | 204 | switch (argc) { |