Commit 20c5f97d authored by Philip Makedonski's avatar Philip Makedonski
Browse files

+ fixed constraint for variant binding, #212

parent b4192cfa
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -116,11 +116,12 @@ context EventTemplateOccurrence
context VariantBinding
  -- Referenced 'Value' of 'VariantBinding'
  inv VariantBindingValues ('If the \'value\' property references a \'LiteralValue\' or \'Content\' element, the referenced element shall be contained in the \'StructuredTestObjective\' containing the \'VariantBinding\'.' + self.toString()):
        self.value.oclIsTypeOf(LiteralValueReference) implies
          self.value.oclAsType(LiteralValueReference).content.getTestObjective() = self.getTestObjective()
        (self.value.oclIsTypeOf(LiteralValueReference) implies
          self.value.oclAsType(LiteralValueReference).content.getTestObjective() = self.getTestObjective())
        and 
          self.value.oclIsKindOf(ContentReference) implies
          self.value.oclAsType(ContentReference).content.getTestObjective() = self.getTestObjective()
        (self.value.oclIsTypeOf(ContentReference) implies
          self.value.oclAsType(ContentReference).content.getTestObjective() = self.getTestObjective())
        -- TODO: check compatibility for types