Skip to content

Commit dbdd40c

Browse files
authored
Merge pull request #1446 from PARTHDESHMUKH2005/patch-2
Update cli-test.py
2 parents 8332715 + c362616 commit dbdd40c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

nipap-cli/tests/cli-test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import unittest
77

88
import sys
9-
sys.path.insert(0, '..')
9+
sys.path.insert(0, os.path.join(os.path.dirname(__file__) ,'..')
1010
from nipap_cli import nipap_cli
1111
from nipap_cli.command import Command, CommandError, InvalidCommand
1212

@@ -33,7 +33,7 @@ def complete_a_option1(arg):
3333

3434
match = []
3535
for straw in [ 'FOO', 'FOD', 'BAR' ]:
36-
if straw.find(arg) == 0:
36+
if straw.startswith(arg):
3737
match.append(straw)
3838

3939
return match

0 commit comments

Comments
 (0)