Skip to content

Commit

Permalink
#12254: ci fix
Browse files Browse the repository at this point in the history
  • Loading branch information
olabetskyi committed Dec 12, 2023
1 parent cb8f21c commit 66ec2bd
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions test/cli/test-other.py
Original file line number Diff line number Diff line change
Expand Up @@ -828,7 +828,7 @@ def test_file_duplicate_2(tmpdir):
assert stderr == ''


def test_premium_with_relative_path(tmpdir):
def test_premium_with_relative_path(tmpdir): #12254


test_file = os.path.join(tmpdir, 'test.c')
Expand All @@ -838,7 +838,7 @@ def test_premium_with_relative_path(tmpdir):
product_name = 'Cppcheck Premium ' + str(time.time())

test_cfg = lookup_cppcheck_exe()
if(test_cfg.endswith('.exe')) :
if(test_cfg.endswith('.exe')):
test_cfg = test_cfg[:-4]
test_cfg += '.cfg'
with open(test_cfg, 'wt') as f:
Expand All @@ -850,7 +850,7 @@ def test_premium_with_relative_path(tmpdir):
}
""".replace('NAME', product_name))

if os.path.isfile('cppcheck') :
if os.path.isfile('cppcheck'):
os.chdir('test/cli')

args = ['--premium=misra-c++-2008', test_file]
Expand All @@ -862,3 +862,5 @@ def test_premium_with_relative_path(tmpdir):
_, stdout, stderr = cppcheck(['--version'])
assert stdout == product_name + '\n'
assert stderr == ''

os.remove(test_cfg)

0 comments on commit 66ec2bd

Please sign in to comment.