Skip to content

Commit 965de29

Browse files
author
Philippe Gil
committed
Remove gprname references in tests as it was removed from gpr2
As gprname is not part of of gprname, remove all gprname related tests from gpr2 testsuite. Closes gpr_issues#146 Merge request eng/gpr/gpr!166 from branch 'mr/gpr_issues-146/updating-tests-after-gprname-removed' into 'master'
2 parents 2c247ab + d153e95 commit 965de29

File tree

5 files changed

+5
-108
lines changed

5 files changed

+5
-108
lines changed

testsuite/tests/command_line/test.out

Lines changed: 0 additions & 96 deletions
Original file line numberDiff line numberDiff line change
@@ -238,45 +238,6 @@ Verbosity switches:
238238
-v Verbose output
239239
-ws Suppress all warnings
240240

241-
-------------------------
242-
gprname -h
243-
-------------------------
244-
Usage: gprname [switches] naming-pattern [naming-patterns]
245-
{--and [switches] naming-pattern [naming-patterns]}
246-
247-
general switches:
248-
--version Display version and exit
249-
-h, --help Display usage and exit
250-
251-
-eL For backwards compatibility, has no effect
252-
-P[ ]<proj> Update or create project file <proj>
253-
254-
--ignore-duplicate-files Ignore duplicate file names
255-
--ignore-predefined-units Ignore predefined units
256-
257-
--no-backup Do not create backup of project file
258-
--target=<targ> Indicates the target of the GNAT compiler
259-
--RTS=<dir> Specify the Ada runtime
260-
261-
-gnateD<sym>=<val> Preprocess with symbol definition
262-
-gnatep=<data> Preprocess files with data file
263-
264-
--minimal-dirs Keep as Source_Dirs only the directories that contain at least one source.
265-
This will also expand any /** suffix to an explicit list of directories.
266-
267-
-v Verbose output
268-
-v -v Very verbose output
269-
-vP<x> Specify verbosity when parsing Project Files (x = 0/1/2)
270-
271-
switches for naming pattern sections:
272-
--and Begin a new naming patterns section
273-
-d[ ]<dir> Use <dir> as one of the source directories for the current section
274-
-D[ ]<file> Get source directories and files from <file>
275-
[-x][ ]<pat> [exclude] pattern <pat> for Ada source
276-
-[x]f[ ]<pat> [exclude] pattern <pat> for C source
277-
-[x]f:<lang>[ ]<pat> [exclude] pattern <pat> for source of language <lang>
278-
279-
280241
-------------------------
281242
gprls --help
282243
-------------------------
@@ -517,45 +478,6 @@ Verbosity switches:
517478
-v Verbose output
518479
-ws Suppress all warnings
519480

520-
-------------------------
521-
gprname --help
522-
-------------------------
523-
Usage: gprname [switches] naming-pattern [naming-patterns]
524-
{--and [switches] naming-pattern [naming-patterns]}
525-
526-
general switches:
527-
--version Display version and exit
528-
-h, --help Display usage and exit
529-
530-
-eL For backwards compatibility, has no effect
531-
-P[ ]<proj> Update or create project file <proj>
532-
533-
--ignore-duplicate-files Ignore duplicate file names
534-
--ignore-predefined-units Ignore predefined units
535-
536-
--no-backup Do not create backup of project file
537-
--target=<targ> Indicates the target of the GNAT compiler
538-
--RTS=<dir> Specify the Ada runtime
539-
540-
-gnateD<sym>=<val> Preprocess with symbol definition
541-
-gnatep=<data> Preprocess files with data file
542-
543-
--minimal-dirs Keep as Source_Dirs only the directories that contain at least one source.
544-
This will also expand any /** suffix to an explicit list of directories.
545-
546-
-v Verbose output
547-
-v -v Very verbose output
548-
-vP<x> Specify verbosity when parsing Project Files (x = 0/1/2)
549-
550-
switches for naming pattern sections:
551-
--and Begin a new naming patterns section
552-
-d[ ]<dir> Use <dir> as one of the source directories for the current section
553-
-D[ ]<file> Get source directories and files from <file>
554-
[-x][ ]<pat> [exclude] pattern <pat> for Ada source
555-
-[x]f[ ]<pat> [exclude] pattern <pat> for C source
556-
-[x]f:<lang>[ ]<pat> [exclude] pattern <pat> for source of language <lang>
557-
558-
559481
-------------------------
560482
gprls --no-such-switch
561483
-------------------------
@@ -577,12 +499,6 @@ gprinstall: unrecognized option '--no-such-switch'
577499
try "gprinstall --help" for more information.
578500
STATUS: 4
579501

580-
-------------------------
581-
gprname --no-such-switch
582-
-------------------------
583-
gprname: wrong switch: --no-such-switch
584-
STATUS: 4
585-
586502
-------------------------
587503
gprls --config:conf.cgpr
588504
-------------------------
@@ -604,12 +520,6 @@ gprinstall: unexpected index for '--config:conf.cgpr'
604520
try "gprinstall --help" for more information.
605521
STATUS: 4
606522

607-
-------------------------
608-
gprname -gnatep:foo
609-
-------------------------
610-
gprname: project file name missing
611-
STATUS: 4
612-
613523
-------------------------
614524
gprls -P
615525
-------------------------
@@ -631,12 +541,6 @@ gprinstall: parameter expected for argument '-P'
631541
try "gprinstall --help" for more information.
632542
STATUS: 4
633543

634-
-------------------------
635-
gprname -P
636-
-------------------------
637-
gprname: project file name missing
638-
STATUS: 4
639-
640544
-------------------------
641545
gprls -s
642546
-------------------------

testsuite/tests/command_line/test.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,11 @@
33
GPRLS,
44
GPRCLEAN,
55
GPRINSTALL,
6-
GPRNAME,
76
)
87

98
bnr = BuilderAndRunner()
109

11-
all_tools = [GPRLS, GPRCLEAN, GPRINSTALL, GPRNAME]
10+
all_tools = [GPRLS, GPRCLEAN, GPRINSTALL]
1211

1312

1413
def execute(cmd, check=False):
@@ -42,10 +41,7 @@ def execute(cmd, check=False):
4241
# check invalid parameter delimiter
4342

4443
for t in all_tools:
45-
if t == GPRNAME:
46-
execute([t, "-gnatep:foo"])
47-
else:
48-
execute([t, "--config:conf.cgpr"])
44+
execute([t, "--config:conf.cgpr"])
4945

5046
# check no parameter
5147

testsuite/tests/display-version/test.out

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
GPRNAME: OK
21
GPRLS: OK
32
GPRINSTALL: OK
43
GPRCLEAN: OK

testsuite/tests/display-version/test.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import re
22

3-
from testsuite_support.builder_and_runner import BuilderAndRunner, GPRNAME, GPRLS, \
3+
from testsuite_support.builder_and_runner import BuilderAndRunner, GPRLS, \
44
GPRINSTALL, GPRCLEAN, GPRCONFIG, \
55
GPRREMOTE
66

@@ -11,7 +11,7 @@ def check(toolname, tool):
1111
try:
1212
p = BuilderAndRunner().run([tool, '--version'])
1313
if p.status != 0:
14-
print('gprname returned ' + str(p.status))
14+
print(toolname + ' returned ' + str(p.status))
1515
print(p.out)
1616
else:
1717
output = p.out
@@ -28,7 +28,6 @@ def check(toolname, tool):
2828
print('*** Error: %s' % str(E))
2929

3030

31-
check('GPRNAME', GPRNAME)
3231
check('GPRLS', GPRLS)
3332
check('GPRINSTALL', GPRINSTALL)
3433
check('GPRCLEAN', GPRCLEAN)

testsuite/testsuite_support/builder_and_runner.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,11 @@
1414
GPRLS = GPR + "ls"
1515
GPRCLEAN = GPR + "clean"
1616
GPRINSTALL = GPR + "install"
17-
GPRNAME = GPR + "name"
1817
GPRCONFIG = GPR + "config"
1918
GPRREMOTE = GPR + "remote"
2019
GPRDOC = GPR + "doc"
2120
GPRINSPECT = GPR + "inspect"
22-
GPRTOOLS = [GPRLS, GPRCLEAN, GPRINSTALL, GPRNAME, GPRCONFIG, GPRREMOTE, GPRDOC, GPRINSPECT]
21+
GPRTOOLS = [GPRLS, GPRCLEAN, GPRINSTALL, GPRCONFIG, GPRREMOTE, GPRDOC, GPRINSPECT]
2322

2423

2524
class BuilderAndRunner(object):

0 commit comments

Comments
 (0)