Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(merge): ensure to have same data type while performing 3-way merge #154

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Commits on Mar 20, 2021

  1. fix(merge): ensure to have same data type while performing 3-way merge

    This PR adds the check to perform 3-way merge only if datatype
    matches to observed state data types else error will be returned.
    
    **Bug Description**:
    merge func silently allows to merge when different data types are
    provided for 3-way merge and this leads merge data will not match to
    expected data. Following is an example:
    ```go
    observed := map[string]interface{}{
    	"key1": "value1",
    	"key2": "value2",
    }
    
    desired := map[string]string{
    	"key1": "value1",
    	"key2": "value2",
    }
    
    got := map[string]interface{}{
    	"key1": "value1",
    	"key2": "value2",
    }
    ```
    
    Signed-off-by: mittachaitu <[email protected]>
    mittachaitu committed Mar 20, 2021
    Configuration menu
    Copy the full SHA
    577ccfb View commit details
    Browse the repository at this point in the history

Commits on Mar 21, 2021

  1. This commit adds UnitTest without last applied state

    Signed-off-by: mittachaitu <[email protected]>
    mittachaitu committed Mar 21, 2021
    Configuration menu
    Copy the full SHA
    eb1b05b View commit details
    Browse the repository at this point in the history