diff options
| author | Tobias Hunger <tobias.hunger@qt.io> | 2019-02-27 15:31:29 +0100 |
|---|---|---|
| committer | Tobias Hunger <tobias.hunger@qt.io> | 2019-02-28 08:08:30 +0000 |
| commit | f2e968b245e0428b75eecb0bb7244a0391e3b355 (patch) | |
| tree | 91669c143ebc9102c683398909c45c90a02dd5e3 /util/cmake/tests/test_parsing.py | |
| parent | 33fe56c630d9e59b2a33e28db5e062323d577d34 (diff) | |
CMake: pro2cmake.py: Handle for loops without block
Handle for loops with a single line of instructions and add a test
for that.
Change-Id: I041ae30f64abcbd3db7df29933647f047b92ede3
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'util/cmake/tests/test_parsing.py')
| -rwxr-xr-x | util/cmake/tests/test_parsing.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/util/cmake/tests/test_parsing.py b/util/cmake/tests/test_parsing.py index dd4e5508f60..2f227e0ba26 100755 --- a/util/cmake/tests/test_parsing.py +++ b/util/cmake/tests/test_parsing.py @@ -180,6 +180,12 @@ def test_for(): assert result[1] == [] +def test_single_line_for(): + result = parse_file(_tests_path + '/data/single_line_for.pro') + assert len(result) == 1 + assert result[0] == [] + + def test_unset(): result = parse_file(_tests_path + '/data/unset.pro') assert len(result) == 1 |
