Skip to content

Commit

Permalink
[WIP]Extends tests for ModuleStream.depends_on_stream()
Browse files Browse the repository at this point in the history
The tests for depends_on_stream() and build_depends_on_stream() is modified to handle empty lists

issue: fedora-modularity#192
  • Loading branch information
athira-selvam committed Mar 13, 2019
1 parent 707a598 commit 7055387
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
11 changes: 10 additions & 1 deletion modulemd/v2/tests/ModulemdTests/modulestream.py
Original file line number Diff line number Diff line change
Expand Up @@ -1036,7 +1036,16 @@ def test_depends_on_stream(self):
'platform', 'f28'), False)

self.assertEqual(stream.depends_on_stream('base', 'f30'), False)
self.assertEqual(stream.depends_on_stream('base', 'f30'), False)
self.assertEqual(
stream.build_depends_on_stream(
'base', 'f30'), False)

self.assertEqual(
stream.depends_on_stream(
'streamname', 'f30'), True)
self.assertEqual(
stream.build_depends_on_stream(
'streamname', 'f30'), True)


if __name__ == '__main__':
Expand Down
5 changes: 4 additions & 1 deletion modulemd/v2/tests/test_data/dependson_v2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,12 @@ data:
- MIT
dependencies:
- buildrequires:
platform: [ f30 ]
platform: [f30]
streamname: [ ]
requires:
platform: [ -f28 ]
streamname: [ ]

references:
community: http://nodejs.org
documentation: http://nodejs.org/en/docs
Expand Down

0 comments on commit 7055387

Please sign in to comment.