Updated config tests

This commit is contained in:
Trial97
2021-03-24 13:32:27 +02:00
committed by Dan Christian Bogos
parent ba090352ec
commit 9099e129da
5 changed files with 194 additions and 279 deletions

View File

@@ -70,7 +70,7 @@ func (onm *OrderedNavigableMap) Remove(fullPath *FullPath) (err error) {
if fullPath.Path == EmptyString {
return ErrWrongPath
}
fullPath.PathItems = CloneSlice(fullPath.PathItems)
fullPath.PathItems = CloneStringSlice(fullPath.PathItems)
if err = onm.nm.Remove(fullPath.PathItems); err != nil {
return
}
@@ -132,7 +132,7 @@ func (onm *OrderedNavigableMap) SetAsSlice(fullPath *FullPath, vals []*DataNode)
pathItmsSet := make([][]string, len(vals))
for i := range vals {
pathItms := CloneSlice(fullPath.PathItems)
pathItms := CloneStringSlice(fullPath.PathItems)
pathItms = append(pathItms, strconv.Itoa(i))
pathItmsSet[i] = pathItms
}