Skip to content

Commit

Permalink
Merge pull request #142 from CiscoTestAutomation/stirpude_fix_wrong_o…
Browse files Browse the repository at this point in the history
…peration_value

Passing values to preferred_create, preferred_replace and preferred_delete parameters while creating ConfigDelta object
  • Loading branch information
Taarini authored Sep 19, 2024
2 parents 6d33531 + 54eb23c commit 91da9f6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
--------------------------------------------------------------------------------
Fix
--------------------------------------------------------------------------------
* yang.ncdiff
* Modified ConfigDelta:
* Updated __neg__ to pass default values of preferred_create, preferred_replace and preferred_delete while creating ConfigDelta object

5 changes: 4 additions & 1 deletion ncdiff/src/yang/ncdiff/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,10 @@ def __str__(self):

def __neg__(self):
return ConfigDelta(config_src=self.config_dst,
config_dst=self.config_src)
config_dst=self.config_src,
preferred_create=self.preferred_create,
preferred_replace=self.preferred_replace,
preferred_delete=self.preferred_delete)

def __pos__(self):
return self
Expand Down

0 comments on commit 91da9f6

Please sign in to comment.