Skip to content

Commit bd6e018

Browse files
committed
[ELF][test] Improve -v and --version tests
1 parent 636de2b commit bd6e018

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

lld/test/ELF/driver.test

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,6 @@
1717
# HELP: USAGE:
1818
# HELP: : supported targets:{{.*}} elf
1919

20-
# RUN: ld.lld --version 2>&1 | FileCheck -check-prefix=VERSION %s
21-
# RUN: ld.lld -v 2>&1 | FileCheck -check-prefix=VERSION %s
22-
# RUN: not ld.lld -v xyz 2>&1 | FileCheck -check-prefix=VERSION %s
23-
# VERSION: LLD {{.*}} (compatible with GNU linkers)
24-
2520
# RUN: not ld.lld --versin 2>&1 | FileCheck -check-prefix=SPELLVERSION %s
2621
# SPELLVERSION: unknown argument '--versin', did you mean '--version'
2722

lld/test/ELF/version.test

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
## --version skips input file processing.
2+
# RUN: ld.lld --version %t/not-exist 2>&1 | FileCheck %s
3+
4+
## -v/-V don't skip processing if there is any input.
5+
# RUN: ld.lld -v 2>&1 | FileCheck %s
6+
# RUN: not ld.lld -v %t/not-exist 2>&1 | FileCheck %s
7+
# RUN: ld.lld -V 2>&1 | FileCheck %s
8+
9+
# CHECK: LLD {{.*}} (compatible with GNU linkers)

0 commit comments

Comments
 (0)