Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- >>> a
- <<class 'pkg.actions.file.FileAction'> object at 0x88ab054: file NOHASH group=staff mode=0644 overlay=true owner=timf path=foo variant.arch=i386 variant.bar=new variant.bar=other>
- >>> b
- <<class 'pkg.actions.file.FileAction'> object at 0x88ab964: file NOHASH group=staff mode=0644 overlay=allow owner=timf path=foo preserve=true variant.arch=i386 variant.bar=other>
- >>> c
- <<class 'pkg.actions.file.FileAction'> object at 0x88abacc: file NOHASH group=staff mode=0644 overlay=allow owner=timf path=foo preserve=true variant.arch=i386 variant.bar=new>
- >>> b_vct = b.get_variant_template()
- >>> c_vct = c.get_variant_template()
- >>> a_vct = a.get_variant_template()
- >>> vc = pkg.variant.VariantCombinations(a_vct, False)
- >>> vc
- VC Sat:[] Unsat:[frozenset([('variant.arch', 'i386'), ('variant.bar', 'other')]), frozenset([('variant.bar', 'new'), ('variant.arch', 'i386')])]
- >>> vc.mark_as_satisfied(pkg.variant.VariantCombinations(b_vct, True)
- ... )
- True
- >>> vc
- VC Sat:[frozenset([('variant.arch', 'i386'), ('variant.bar', 'other')])] Unsat:[frozenset([('variant.bar', 'new'), ('variant.arch', 'i386')])]
- >>> vc.mark_as_satisfied(pkg.variant.VariantCombinations(c_vct, True)
- ... )
- True
- >>> vc
- VC Sat:[frozenset([('variant.arch', 'i386'), ('variant.bar', 'other')]), frozenset([('variant.bar', 'new'), ('variant.arch', 'i386')])] Unsat:[]
- >>>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement