Skip to content

Commit 1fe6cd0

Browse files
committed
[readtapi][tests] add descriptions to tests (llvm#73576)
(cherry picked from commit 4d29bda)
1 parent 2484d02 commit 1fe6cd0

File tree

4 files changed

+9
-0
lines changed

4 files changed

+9
-0
lines changed

llvm/test/tools/llvm-readtapi/command-line.test

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
; RUN: llvm-readtapi --help 2>&1 | FileCheck %s
22
; RUN: llvm-readtapi -help 2>&1 | FileCheck %s
3+
// Check mutually exclusive options.
34
; RUN: not llvm-readtapi -merge -compare -compact %t/tmp.tbd %t/tmp2.tbd 2>&1 | FileCheck %s --check-prefix MULTI_ACTION
5+
// Check unsupported file output format.
46
; RUN: not llvm-readtapi -merge -compact %t/tmp.tbd %t/tmp2.tbd --filetype=tbd-v2 2>&1 | FileCheck %s --check-prefix FILE_FORMAT
57

68
CHECK: OVERVIEW: LLVM TAPI file reader and manipulator

llvm/test/tools/llvm-readtapi/extract-invalid.test

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
; RUN: rm -rf %t
22
; RUN: split-file %s %t
3+
// Check readtapi only accepts one file.
34
; RUN: not llvm-readtapi -extract %t/libfoo.tbd %t/libbar.tbd 2>&1 | FileCheck %s --allow-empty --check-prefix EXTRA
5+
// Check missing argument.
46
; RUN: not llvm-readtapi -extract %t/libfoo.tbd 2>&1 | FileCheck %s --allow-empty --check-prefix MISSING
7+
// Check that TBD file manipulation was not valid and error propagated as expected.
58
; RUN: not llvm-readtapi -arch x86_64 -extract %t/libfoo.tbd 2>&1 | FileCheck %s --allow-empty --check-prefix MISMATCH
69

710
; EXTRA: error: extract only supports one input file

llvm/test/tools/llvm-readtapi/merge-invalid.test

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
; RUN: rm -rf %t
22
; RUN: split-file %s %t
3+
// Check invalid tbd file contents was propagated as error.
34
; RUN: not llvm-readtapi -merge %t/libfoo.tbd %t/libbar.tbd 2>&1 | FileCheck %s --allow-empty --check-prefix DIFF
5+
// Check missing input.
46
; RUN: not llvm-readtapi -merge %t/libfoo.tbd 2>&1 | FileCheck %s --allow-empty --check-prefix INPUT
57

68
; DIFF: install names do not match

llvm/test/tools/llvm-readtapi/remove.test

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
; RUN: rm -rf %t
22
; RUN: split-file %s %t
3+
// Check that arch removal is accepted with tbdv5 and various inlined contents.
4+
35
; RUN: llvm-readtapi --remove -arch x86_64h %t/libfat.tbd -o %t/libslim.tbd 2>&1 | FileCheck --allow-empty %s
46
; RUN: llvm-readtapi --compare %t/libslim.tbd %t/libslim_expected.tbd
57

0 commit comments

Comments
 (0)