github.com/jbendotnet/noms@v0.0.0-20190904222105-c43e4293ea92/cmd/noms/noms_log_test.go (about) 1 // Copyright 2016 Attic Labs, Inc. All rights reserved. 2 // Licensed under the Apache License, version 2.0: 3 // http://www.apache.org/licenses/LICENSE-2.0 4 5 package main 6 7 import ( 8 "testing" 9 10 "github.com/attic-labs/noms/go/datas" 11 "github.com/attic-labs/noms/go/spec" 12 "github.com/attic-labs/noms/go/types" 13 "github.com/attic-labs/noms/go/util/clienttest" 14 "github.com/attic-labs/noms/go/util/test" 15 "github.com/stretchr/testify/assert" 16 "github.com/stretchr/testify/suite" 17 ) 18 19 func TestNomsLog(t *testing.T) { 20 suite.Run(t, &nomsLogTestSuite{}) 21 } 22 23 type nomsLogTestSuite struct { 24 clienttest.ClientTestSuite 25 } 26 27 func testCommitInResults(s *nomsLogTestSuite, str string, i int) { 28 sp, err := spec.ForDataset(str) 29 s.NoError(err) 30 defer sp.Close() 31 32 sp.GetDatabase().CommitValue(sp.GetDataset(), types.Number(i)) 33 s.NoError(err) 34 35 commit := sp.GetDataset().Head() 36 res, _ := s.MustRun(main, []string{"log", str}) 37 s.Contains(res, commit.Hash().String()) 38 } 39 40 func (s *nomsLogTestSuite) TestNomsLog() { 41 sp, err := spec.ForDataset(spec.CreateValueSpecString("nbs", s.DBDir, "dsTest")) 42 s.NoError(err) 43 defer sp.Close() 44 45 sp.GetDatabase() // create the database 46 //s.Panics(func() { s.MustRun(main, []string{"log", sp.String()}) }) 47 48 testCommitInResults(s, sp.String(), 1) 49 testCommitInResults(s, sp.String(), 2) 50 } 51 52 func (s *nomsLogTestSuite) TestNomsLogPath() { 53 sp, err := spec.ForPath(spec.CreateValueSpecString("nbs", s.DBDir, "dsTest.value.bar")) 54 s.NoError(err) 55 defer sp.Close() 56 57 db := sp.GetDatabase() 58 ds := sp.GetDataset() 59 for i := 0; i < 3; i++ { 60 data := types.NewStruct("", types.StructData{ 61 "bar": types.Number(i), 62 }) 63 ds, err = db.CommitValue(ds, data) 64 s.NoError(err) 65 } 66 67 stdout, stderr := s.MustRun(main, []string{"log", "--show-value", sp.String()}) 68 s.Empty(stderr) 69 test.EqualsIgnoreHashes(s.T(), pathValue, stdout) 70 71 stdout, stderr = s.MustRun(main, []string{"log", sp.String()}) 72 s.Empty(stderr) 73 test.EqualsIgnoreHashes(s.T(), pathDiff, stdout) 74 } 75 76 func addCommit(ds datas.Dataset, v string) (datas.Dataset, error) { 77 return ds.Database().CommitValue(ds, types.String(v)) 78 } 79 80 func addCommitWithValue(ds datas.Dataset, v types.Value) (datas.Dataset, error) { 81 return ds.Database().CommitValue(ds, v) 82 } 83 84 func addBranchedDataset(vrw types.ValueReadWriter, newDs, parentDs datas.Dataset, v string) (datas.Dataset, error) { 85 p := types.NewSet(vrw, parentDs.HeadRef()) 86 return newDs.Database().Commit(newDs, types.String(v), datas.CommitOptions{Parents: p}) 87 } 88 89 func mergeDatasets(vrw types.ValueReadWriter, ds1, ds2 datas.Dataset, v string) (datas.Dataset, error) { 90 p := types.NewSet(vrw, ds1.HeadRef(), ds2.HeadRef()) 91 return ds1.Database().Commit(ds1, types.String(v), datas.CommitOptions{Parents: p}) 92 } 93 94 func (s *nomsLogTestSuite) TestNArg() { 95 dsName := "nArgTest" 96 97 sp, err := spec.ForDatabase(spec.CreateDatabaseSpecString("nbs", s.DBDir)) 98 s.NoError(err) 99 defer sp.Close() 100 101 ds := sp.GetDatabase().GetDataset(dsName) 102 103 ds, err = addCommit(ds, "1") 104 h1 := ds.Head().Hash() 105 s.NoError(err) 106 ds, err = addCommit(ds, "2") 107 s.NoError(err) 108 h2 := ds.Head().Hash() 109 ds, err = addCommit(ds, "3") 110 s.NoError(err) 111 h3 := ds.Head().Hash() 112 113 dsSpec := spec.CreateValueSpecString("nbs", s.DBDir, dsName) 114 res, _ := s.MustRun(main, []string{"log", "-n1", dsSpec}) 115 s.NotContains(res, h1.String()) 116 res, _ = s.MustRun(main, []string{"log", "-n0", dsSpec}) 117 s.Contains(res, h3.String()) 118 s.Contains(res, h2.String()) 119 s.Contains(res, h1.String()) 120 121 vSpec := spec.CreateValueSpecString("nbs", s.DBDir, "#"+h3.String()) 122 res, _ = s.MustRun(main, []string{"log", "-n1", vSpec}) 123 s.NotContains(res, h1.String()) 124 res, _ = s.MustRun(main, []string{"log", "-n0", vSpec}) 125 s.Contains(res, h3.String()) 126 s.Contains(res, h2.String()) 127 s.Contains(res, h1.String()) 128 } 129 130 func (s *nomsLogTestSuite) TestEmptyCommit() { 131 sp, err := spec.ForDatabase(spec.CreateDatabaseSpecString("nbs", s.DBDir)) 132 s.NoError(err) 133 defer sp.Close() 134 135 db := sp.GetDatabase() 136 ds := db.GetDataset("ds1") 137 138 meta := types.NewStruct("Meta", map[string]types.Value{ 139 "longNameForTest": types.String("Yoo"), 140 "test2": types.String("Hoo"), 141 }) 142 ds, err = db.Commit(ds, types.String("1"), datas.CommitOptions{Meta: meta}) 143 s.NoError(err) 144 145 ds, err = db.Commit(ds, types.String("2"), datas.CommitOptions{}) 146 s.NoError(err) 147 148 dsSpec := spec.CreateValueSpecString("nbs", s.DBDir, "ds1") 149 res, _ := s.MustRun(main, []string{"log", dsSpec}) 150 test.EqualsIgnoreHashes(s.T(), metaRes1, res) 151 152 res, _ = s.MustRun(main, []string{"log", "--oneline", dsSpec}) 153 test.EqualsIgnoreHashes(s.T(), metaRes2, res) 154 } 155 156 func (s *nomsLogTestSuite) TestNomsGraph1() { 157 sp, err := spec.ForDatabase(spec.CreateDatabaseSpecString("nbs", s.DBDir)) 158 s.NoError(err) 159 defer sp.Close() 160 161 db := sp.GetDatabase() 162 163 b1 := db.GetDataset("b1") 164 b1, err = addCommit(b1, "1") 165 s.NoError(err) 166 b1, err = addCommit(b1, "2") 167 s.NoError(err) 168 b1, err = addCommit(b1, "3") 169 s.NoError(err) 170 171 b2 := db.GetDataset("b2") 172 b2, err = addBranchedDataset(db, b2, b1, "3.1") 173 s.NoError(err) 174 175 b1, err = addCommit(b1, "3.2") 176 s.NoError(err) 177 b1, err = addCommit(b1, "3.6") 178 s.NoError(err) 179 180 b3 := db.GetDataset("b3") 181 b3, err = addBranchedDataset(db, b3, b2, "3.1.3") 182 s.NoError(err) 183 b3, err = addCommit(b3, "3.1.5") 184 s.NoError(err) 185 b3, err = addCommit(b3, "3.1.7") 186 s.NoError(err) 187 188 b2, err = mergeDatasets(db, b2, b3, "3.5") 189 s.NoError(err) 190 b2, err = addCommit(b2, "3.7") 191 s.NoError(err) 192 193 b1, err = mergeDatasets(db, b1, b2, "4") 194 s.NoError(err) 195 196 b1, err = addCommit(b1, "5") 197 s.NoError(err) 198 b1, err = addCommit(b1, "6") 199 s.NoError(err) 200 b1, err = addCommit(b1, "7") 201 s.NoError(err) 202 203 res, _ := s.MustRun(main, []string{"log", "--graph", "--show-value", spec.CreateValueSpecString("nbs", s.DBDir, "b1")}) 204 s.Equal(graphRes1, res) 205 res, _ = s.MustRun(main, []string{"log", "--graph", spec.CreateValueSpecString("nbs", s.DBDir, "b1")}) 206 s.Equal(diffRes1, res) 207 } 208 209 func (s *nomsLogTestSuite) TestNomsGraph2() { 210 sp, err := spec.ForDatabase(spec.CreateDatabaseSpecString("nbs", s.DBDir)) 211 s.NoError(err) 212 defer sp.Close() 213 214 db := sp.GetDatabase() 215 216 ba := db.GetDataset("ba") 217 ba, err = addCommit(ba, "1") 218 s.NoError(err) 219 220 bb := db.GetDataset("bb") 221 bb, err = addCommit(bb, "10") 222 s.NoError(err) 223 224 bc := db.GetDataset("bc") 225 bc, err = addCommit(bc, "100") 226 s.NoError(err) 227 228 ba, err = mergeDatasets(db, ba, bb, "11") 229 s.NoError(err) 230 231 _, err = mergeDatasets(db, ba, bc, "101") 232 s.NoError(err) 233 234 res, _ := s.MustRun(main, []string{"log", "--graph", "--show-value", spec.CreateValueSpecString("nbs", s.DBDir, "ba")}) 235 s.Equal(graphRes2, res) 236 res, _ = s.MustRun(main, []string{"log", "--graph", spec.CreateValueSpecString("nbs", s.DBDir, "ba")}) 237 s.Equal(diffRes2, res) 238 } 239 240 func (s *nomsLogTestSuite) TestNomsGraph3() { 241 sp, err := spec.ForDatabase(spec.CreateDatabaseSpecString("nbs", s.DBDir)) 242 s.NoError(err) 243 defer sp.Close() 244 245 db := sp.GetDatabase() 246 247 w := db.GetDataset("w") 248 249 w, err = addCommit(w, "1") 250 s.NoError(err) 251 252 w, err = addCommit(w, "2") 253 s.NoError(err) 254 255 x := db.GetDataset("x") 256 x, err = addBranchedDataset(db, x, w, "20-x") 257 s.NoError(err) 258 259 y := db.GetDataset("y") 260 y, err = addBranchedDataset(db, y, w, "200-y") 261 s.NoError(err) 262 263 z := db.GetDataset("z") 264 z, err = addBranchedDataset(db, z, w, "2000-z") 265 s.NoError(err) 266 267 w, err = mergeDatasets(db, w, x, "22-wx") 268 s.NoError(err) 269 270 w, err = mergeDatasets(db, w, y, "222-wy") 271 s.NoError(err) 272 273 _, err = mergeDatasets(db, w, z, "2222-wz") 274 s.NoError(err) 275 276 res, _ := s.MustRun(main, []string{"log", "--graph", "--show-value", spec.CreateValueSpecString("nbs", s.DBDir, "w")}) 277 test.EqualsIgnoreHashes(s.T(), graphRes3, res) 278 res, _ = s.MustRun(main, []string{"log", "--graph", spec.CreateValueSpecString("nbs", s.DBDir, "w")}) 279 test.EqualsIgnoreHashes(s.T(), diffRes3, res) 280 } 281 282 func (s *nomsLogTestSuite) TestTruncation() { 283 sp, err := spec.ForDatabase(spec.CreateDatabaseSpecString("nbs", s.DBDir)) 284 s.NoError(err) 285 defer sp.Close() 286 db := sp.GetDatabase() 287 288 toNomsList := func(l []string) types.List { 289 nv := []types.Value{} 290 for _, v := range l { 291 nv = append(nv, types.String(v)) 292 } 293 return types.NewList(db, nv...) 294 } 295 296 t := db.GetDataset("truncate") 297 298 t, err = addCommit(t, "the first line") 299 s.NoError(err) 300 301 l := []string{"one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten", "eleven"} 302 _, err = addCommitWithValue(t, toNomsList(l)) 303 s.NoError(err) 304 305 dsSpec := spec.CreateValueSpecString("nbs", s.DBDir, "truncate") 306 res, _ := s.MustRun(main, []string{"log", "--graph", "--show-value", dsSpec}) 307 test.EqualsIgnoreHashes(s.T(), truncRes1, res) 308 res, _ = s.MustRun(main, []string{"log", "--graph", dsSpec}) 309 test.EqualsIgnoreHashes(s.T(), diffTrunc1, res) 310 311 res, _ = s.MustRun(main, []string{"log", "--graph", "--show-value", "--max-lines=-1", dsSpec}) 312 test.EqualsIgnoreHashes(s.T(), truncRes2, res) 313 res, _ = s.MustRun(main, []string{"log", "--graph", "--max-lines=-1", dsSpec}) 314 test.EqualsIgnoreHashes(s.T(), diffTrunc2, res) 315 316 res, _ = s.MustRun(main, []string{"log", "--graph", "--show-value", "--max-lines=0", dsSpec}) 317 test.EqualsIgnoreHashes(s.T(), truncRes3, res) 318 res, _ = s.MustRun(main, []string{"log", "--graph", "--max-lines=0", dsSpec}) 319 test.EqualsIgnoreHashes(s.T(), diffTrunc3, res) 320 } 321 322 func TestBranchlistSplice(t *testing.T) { 323 assert := assert.New(t) 324 bl := branchList{} 325 for i := 0; i < 4; i++ { 326 bl = bl.Splice(0, 0, branch{}) 327 } 328 assert.Equal(4, len(bl)) 329 bl = bl.Splice(3, 1) 330 bl = bl.Splice(0, 1) 331 bl = bl.Splice(1, 1) 332 bl = bl.Splice(0, 1) 333 assert.Zero(len(bl)) 334 335 for i := 0; i < 4; i++ { 336 bl = bl.Splice(0, 0, branch{}) 337 } 338 assert.Equal(4, len(bl)) 339 340 branchesToDelete := []int{1, 2, 3} 341 bl = bl.RemoveBranches(branchesToDelete) 342 assert.Equal(1, len(bl)) 343 } 344 345 const ( 346 graphRes1 = "* cmvkhq582litl19dtf9rdr27lkmmjl5a\n| Parent: n34kv1pmaq511ej6hpvqf6nun0nfsva6\n| \"7\"\n| \n* n34kv1pmaq511ej6hpvqf6nun0nfsva6\n| Parent: j9nk6bv9r7ep1j459j0mv2clof6s7792\n| \"6\"\n| \n* j9nk6bv9r7ep1j459j0mv2clof6s7792\n| Parent: 8rkr9of92el4fvg2quhflro7615roouc\n| \"5\"\n| \n* 8rkr9of92el4fvg2quhflro7615roouc\n|\\ Merge: r4c42m0u4k8g08ivo005p1k3e9c8a3tq n05ujdtqd9enisrbcrifhc6n41anur3g\n| | \"4\"\n| | \n| * n05ujdtqd9enisrbcrifhc6n41anur3g\n| | Parent: 6eu8a3l1gunugn7uinotiv8saf783pok\n| | \"3.7\"\n| | \n| * 6eu8a3l1gunugn7uinotiv8saf783pok\n| |\\ Merge: 92u4ja5p42gr6galrq7o5ubad98qk3pp f464nqgept56er12l7ikaj9jhrdrckb7\n| | | \"3.5\"\n| | | \n| | * f464nqgept56er12l7ikaj9jhrdrckb7\n| | | Parent: gjggba0bhcjd10kmooemvbvr4gnokdcm\n| | | \"3.1.7\"\n| | | \n| | * gjggba0bhcjd10kmooemvbvr4gnokdcm\n| | | Parent: q7gc5legocg4gq4qfd2v0i41sm9q2p9d\n| | | \"3.1.5\"\n| | | \n* | | r4c42m0u4k8g08ivo005p1k3e9c8a3tq\n| | | Parent: 885bl3ggjtnf9e4h4d3cnidh576hm27u\n| | | \"3.6\"\n| | | \n| | * q7gc5legocg4gq4qfd2v0i41sm9q2p9d\n| | | Parent: 92u4ja5p42gr6galrq7o5ubad98qk3pp\n| | | \"3.1.3\"\n| | | \n* | | 885bl3ggjtnf9e4h4d3cnidh576hm27u\n| |/ Parent: 7f8hmd1okp98ovnph695kumm4lknuqcd\n| | \"3.2\"\n| | \n| * 92u4ja5p42gr6galrq7o5ubad98qk3pp\n|/ Parent: 7f8hmd1okp98ovnph695kumm4lknuqcd\n| \"3.1\"\n| \n* 7f8hmd1okp98ovnph695kumm4lknuqcd\n| Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| \"3\"\n| \n* 2r6g3brn1867i66rri1suk49fev2js7b\n| Parent: ppu3smo89vu0bdukubgooo8efeo1i7q3\n| \"2\"\n| \n* ppu3smo89vu0bdukubgooo8efeo1i7q3\n| Parent: None\n| \"1\"\n" 347 diffRes1 = "* cmvkhq582litl19dtf9rdr27lkmmjl5a\n| Parent: n34kv1pmaq511ej6hpvqf6nun0nfsva6\n| - \"6\"\n| + \"7\"\n| \n* n34kv1pmaq511ej6hpvqf6nun0nfsva6\n| Parent: j9nk6bv9r7ep1j459j0mv2clof6s7792\n| - \"5\"\n| + \"6\"\n| \n* j9nk6bv9r7ep1j459j0mv2clof6s7792\n| Parent: 8rkr9of92el4fvg2quhflro7615roouc\n| - \"4\"\n| + \"5\"\n| \n* 8rkr9of92el4fvg2quhflro7615roouc\n|\\ Merge: r4c42m0u4k8g08ivo005p1k3e9c8a3tq n05ujdtqd9enisrbcrifhc6n41anur3g\n| | - \"3.6\"\n| | + \"4\"\n| | \n| * n05ujdtqd9enisrbcrifhc6n41anur3g\n| | Parent: 6eu8a3l1gunugn7uinotiv8saf783pok\n| | - \"3.5\"\n| | + \"3.7\"\n| | \n| * 6eu8a3l1gunugn7uinotiv8saf783pok\n| |\\ Merge: 92u4ja5p42gr6galrq7o5ubad98qk3pp f464nqgept56er12l7ikaj9jhrdrckb7\n| | | - \"3.1\"\n| | | + \"3.5\"\n| | | \n| | * f464nqgept56er12l7ikaj9jhrdrckb7\n| | | Parent: gjggba0bhcjd10kmooemvbvr4gnokdcm\n| | | - \"3.1.5\"\n| | | + \"3.1.7\"\n| | | \n| | * gjggba0bhcjd10kmooemvbvr4gnokdcm\n| | | Parent: q7gc5legocg4gq4qfd2v0i41sm9q2p9d\n| | | - \"3.1.3\"\n| | | + \"3.1.5\"\n| | | \n* | | r4c42m0u4k8g08ivo005p1k3e9c8a3tq\n| | | Parent: 885bl3ggjtnf9e4h4d3cnidh576hm27u\n| | | - \"3.2\"\n| | | + \"3.6\"\n| | | \n| | * q7gc5legocg4gq4qfd2v0i41sm9q2p9d\n| | | Parent: 92u4ja5p42gr6galrq7o5ubad98qk3pp\n| | | - \"3.1\"\n| | | + \"3.1.3\"\n| | | \n* | | 885bl3ggjtnf9e4h4d3cnidh576hm27u\n| |/ Parent: 7f8hmd1okp98ovnph695kumm4lknuqcd\n| | - \"3\"\n| | + \"3.2\"\n| | \n| * 92u4ja5p42gr6galrq7o5ubad98qk3pp\n|/ Parent: 7f8hmd1okp98ovnph695kumm4lknuqcd\n| - \"3\"\n| + \"3.1\"\n| \n* 7f8hmd1okp98ovnph695kumm4lknuqcd\n| Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| - \"2\"\n| + \"3\"\n| \n* 2r6g3brn1867i66rri1suk49fev2js7b\n| Parent: ppu3smo89vu0bdukubgooo8efeo1i7q3\n| - \"1\"\n| + \"2\"\n| \n* ppu3smo89vu0bdukubgooo8efeo1i7q3\n| Parent: None\n| \n" 348 349 graphRes2 = "* 3vtsgav7kotnm4t0g441oah0fhc8f612\n|\\ Merge: mlfoejp9rhuq4mlmedvceq46ecofu4fm 5tfaqaak42q0iq8p8d5ej8ju1p1o18t6\n| | \"101\"\n| | \n| * 5tfaqaak42q0iq8p8d5ej8ju1p1o18t6\n| |\\ Merge: ppu3smo89vu0bdukubgooo8efeo1i7q3 7f0obrqkr8pge2o0r6tgkub7jikl0638\n| | | \"11\"\n| | | \n* | mlfoejp9rhuq4mlmedvceq46ecofu4fm\n| | Parent: None\n| | \"100\"\n| | \n* ppu3smo89vu0bdukubgooo8efeo1i7q3\n| Parent: None\n| \"1\"\n| \n* 7f0obrqkr8pge2o0r6tgkub7jikl0638\n| Parent: None\n| \"10\"\n" 350 diffRes2 = "* 3vtsgav7kotnm4t0g441oah0fhc8f612\n|\\ Merge: mlfoejp9rhuq4mlmedvceq46ecofu4fm 5tfaqaak42q0iq8p8d5ej8ju1p1o18t6\n| | - \"100\"\n| | + \"101\"\n| | \n| * 5tfaqaak42q0iq8p8d5ej8ju1p1o18t6\n| |\\ Merge: ppu3smo89vu0bdukubgooo8efeo1i7q3 7f0obrqkr8pge2o0r6tgkub7jikl0638\n| | | - \"1\"\n| | | + \"11\"\n| | | \n* | mlfoejp9rhuq4mlmedvceq46ecofu4fm\n| | Parent: None\n| | \n* ppu3smo89vu0bdukubgooo8efeo1i7q3\n| Parent: None\n| \n* 7f0obrqkr8pge2o0r6tgkub7jikl0638\n| Parent: None\n| \n" 351 352 graphRes3 = "* l2pilhhluk535j4620taktd87tr7bma3\n|\\ Merge: v4qkffjhedt7nmu1n8b95csd9g646iki mjneuuiveli2coui1qjm7rbr4acpaq7c\n| | \"2222-wz\"\n| | \n| * mjneuuiveli2coui1qjm7rbr4acpaq7c\n| |\\ Merge: p5pgg27dcgclv02mlde0qfmuud21mmlj mpagh8od3kpjigrl6pt3atj5bofs8tel\n| | | \"222-wy\"\n| | | \n| | * mpagh8od3kpjigrl6pt3atj5bofs8tel\n| | |\\ Merge: 2r6g3brn1867i66rri1suk49fev2js7b 5ve449uov4tl9f8gmgvf3jpj9cc32iu4\n| | | | \"22-wx\"\n| | | | \n* | | | v4qkffjhedt7nmu1n8b95csd9g646iki\n| | | | Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| | | | \"2000-z\"\n| | | | \n| * | | p5pgg27dcgclv02mlde0qfmuud21mmlj\n| | | | Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| | | | \"200-y\"\n| | | | \n| | | * 5ve449uov4tl9f8gmgvf3jpj9cc32iu4\n|/ / / Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| \"20-x\"\n| \n* 2r6g3brn1867i66rri1suk49fev2js7b\n| Parent: ppu3smo89vu0bdukubgooo8efeo1i7q3\n| \"2\"\n| \n* ppu3smo89vu0bdukubgooo8efeo1i7q3\n| Parent: None\n| \"1\"\n" 353 diffRes3 = "* l2pilhhluk535j4620taktd87tr7bma3\n|\\ Merge: v4qkffjhedt7nmu1n8b95csd9g646iki mjneuuiveli2coui1qjm7rbr4acpaq7c\n| | - \"2000-z\"\n| | + \"2222-wz\"\n| | \n| * mjneuuiveli2coui1qjm7rbr4acpaq7c\n| |\\ Merge: p5pgg27dcgclv02mlde0qfmuud21mmlj mpagh8od3kpjigrl6pt3atj5bofs8tel\n| | | - \"200-y\"\n| | | + \"222-wy\"\n| | | \n| | * mpagh8od3kpjigrl6pt3atj5bofs8tel\n| | |\\ Merge: 2r6g3brn1867i66rri1suk49fev2js7b 5ve449uov4tl9f8gmgvf3jpj9cc32iu4\n| | | | - \"2\"\n| | | | + \"22-wx\"\n| | | | \n* | | | v4qkffjhedt7nmu1n8b95csd9g646iki\n| | | | Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| | | | - \"2\"\n| | | | + \"2000-z\"\n| | | | \n| * | | p5pgg27dcgclv02mlde0qfmuud21mmlj\n| | | | Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| | | | - \"2\"\n| | | | + \"200-y\"\n| | | | \n| | | * 5ve449uov4tl9f8gmgvf3jpj9cc32iu4\n|/ / / Parent: 2r6g3brn1867i66rri1suk49fev2js7b\n| - \"2\"\n| + \"20-x\"\n| \n* 2r6g3brn1867i66rri1suk49fev2js7b\n| Parent: ppu3smo89vu0bdukubgooo8efeo1i7q3\n| - \"1\"\n| + \"2\"\n| \n* ppu3smo89vu0bdukubgooo8efeo1i7q3\n| Parent: None\n| \n" 354 355 truncRes1 = "* p1442asfqnhgv1ebg6rijhl3kb9n4vt3\n| Parent: 4tq9si4tk8n0pead7hovehcbuued45sa\n| [ // 11 items\n| \"one\",\n| \"two\",\n| \"three\",\n| \"four\",\n| \"five\",\n| \"six\",\n| \"seven\",\n| ...\n| \n* 4tq9si4tk8n0pead7hovehcbuued45sa\n| Parent: None\n| \"the first line\"\n" 356 diffTrunc1 = "* p1442asfqnhgv1ebg6rijhl3kb9n4vt3\n| Parent: 4tq9si4tk8n0pead7hovehcbuued45sa\n| - \"the first line\"\n| + [ // 11 items\n| + \"one\",\n| + \"two\",\n| + \"three\",\n| + \"four\",\n| + \"five\",\n| + \"six\",\n| ...\n| \n* 4tq9si4tk8n0pead7hovehcbuued45sa\n| Parent: None\n| \n" 357 358 truncRes2 = "* p1442asfqnhgv1ebg6rijhl3kb9n4vt3\n| Parent: 4tq9si4tk8n0pead7hovehcbuued45sa\n| [ // 11 items\n| \"one\",\n| \"two\",\n| \"three\",\n| \"four\",\n| \"five\",\n| \"six\",\n| \"seven\",\n| \"eight\",\n| \"nine\",\n| \"ten\",\n| \"eleven\",\n| ]\n| \n* 4tq9si4tk8n0pead7hovehcbuued45sa\n| Parent: None\n| \"the first line\"\n" 359 diffTrunc2 = "* p1442asfqnhgv1ebg6rijhl3kb9n4vt3\n| Parent: 4tq9si4tk8n0pead7hovehcbuued45sa\n| - \"the first line\"\n| + [ // 11 items\n| + \"one\",\n| + \"two\",\n| + \"three\",\n| + \"four\",\n| + \"five\",\n| + \"six\",\n| + \"seven\",\n| + \"eight\",\n| + \"nine\",\n| + \"ten\",\n| + \"eleven\",\n| + ]\n| \n* 4tq9si4tk8n0pead7hovehcbuued45sa\n| Parent: None\n| \n" 360 361 truncRes3 = "* p1442asfqnhgv1ebg6rijhl3kb9n4vt3\n| Parent: 4tq9si4tk8n0pead7hovehcbuued45sa\n* 4tq9si4tk8n0pead7hovehcbuued45sa\n| Parent: None\n" 362 diffTrunc3 = "* p1442asfqnhgv1ebg6rijhl3kb9n4vt3\n| Parent: 4tq9si4tk8n0pead7hovehcbuued45sa\n* 4tq9si4tk8n0pead7hovehcbuued45sa\n| Parent: None\n" 363 364 metaRes1 = "p7jmuh67vhfccnqk1bilnlovnms1m67o\nParent: f8gjiv5974ojir9tnrl2k393o4s1tf0r\n- \"1\"\n+ \"2\"\n\nf8gjiv5974ojir9tnrl2k393o4s1tf0r\nParent: None\nLongNameForTest: \"Yoo\"\nTest2: \"Hoo\"\n\n" 365 metaRes2 = "p7jmuh67vhfccnqk1bilnlovnms1m67o (Parent: f8gjiv5974ojir9tnrl2k393o4s1tf0r)\nf8gjiv5974ojir9tnrl2k393o4s1tf0r (Parent: None)\n" 366 367 pathValue = "oki4cv7vkh743rccese3r3omf6l6mao4\nParent: lca4vejkm0iqsk7ok5322pt61u4otn6q\n2\n\nlca4vejkm0iqsk7ok5322pt61u4otn6q\nParent: u42pi8ukgkvpoi6n7d46cklske41oguf\n1\n\nu42pi8ukgkvpoi6n7d46cklske41oguf\nParent: hgmlqmsnrb3sp9jqc6mas8kusa1trrs2\n0\n\nhgmlqmsnrb3sp9jqc6mas8kusa1trrs2\nParent: hffiuecdpoq622tamm3nvungeca99ohl\n<nil>\nhffiuecdpoq622tamm3nvungeca99ohl\nParent: None\n<nil>\n" 368 369 pathDiff = "oki4cv7vkh743rccese3r3omf6l6mao4\nParent: lca4vejkm0iqsk7ok5322pt61u4otn6q\n- 1\n+ 2\n\nlca4vejkm0iqsk7ok5322pt61u4otn6q\nParent: u42pi8ukgkvpoi6n7d46cklske41oguf\n- 0\n+ 1\n\nu42pi8ukgkvpoi6n7d46cklske41oguf\nParent: hgmlqmsnrb3sp9jqc6mas8kusa1trrs2\nold (#hgmlqmsnrb3sp9jqc6mas8kusa1trrs2.value.bar) not found\n\nhgmlqmsnrb3sp9jqc6mas8kusa1trrs2\nParent: hffiuecdpoq622tamm3nvungeca99ohl\nnew (#hgmlqmsnrb3sp9jqc6mas8kusa1trrs2.value.bar) not found\nold (#hffiuecdpoq622tamm3nvungeca99ohl.value.bar) not found\n\nhffiuecdpoq622tamm3nvungeca99ohl\nParent: None\n\n" 370 )