(t *testing.T)
| 469 | } |
| 470 | |
| 471 | func TestBase64(t *testing.T) { |
| 472 | ctx := context.Background() |
| 473 | r := fstest.NewRun(t) |
| 474 | err := transform.SetOptions(ctx, "all,base64encode") |
| 475 | require.NoError(t, err) |
| 476 | file1 := r.WriteFile("toe/toe/toe.txt", "hello world", t1) |
| 477 | |
| 478 | r.Mkdir(ctx, r.Fremote) |
| 479 | ctx = predictDstFromLogger(ctx) |
| 480 | err = Sync(ctx, r.Fremote, r.Flocal, true) |
| 481 | testLoggerVsLsf(ctx, r.Fremote, r.Flocal, operations.GetLoggerOpt(ctx).JSON, t) |
| 482 | require.NoError(t, err) |
| 483 | |
| 484 | r.CheckLocalItems(t, file1) |
| 485 | r.CheckRemoteItems(t, fstest.NewItem("dG9l/dG9l/dG9lLnR4dA==", "hello world", t1)) |
| 486 | |
| 487 | // round trip |
| 488 | err = transform.SetOptions(ctx, "all,base64decode") |
| 489 | require.NoError(t, err) |
| 490 | ctx = predictDstFromLogger(ctx) |
| 491 | err = Sync(ctx, r.Flocal, r.Fremote, true) |
| 492 | testLoggerVsLsf(ctx, r.Flocal, r.Fremote, operations.GetLoggerOpt(ctx).JSON, t) |
| 493 | require.NoError(t, err) |
| 494 | |
| 495 | r.CheckLocalItems(t, file1) |
| 496 | r.CheckRemoteItems(t, fstest.NewItem("dG9l/dG9l/dG9lLnR4dA==", "hello world", t1)) |
| 497 | } |
| 498 | |
| 499 | func TestError(t *testing.T) { |
| 500 | ctx := context.Background() |
nothing calls this directly
no test coverage detected
searching dependent graphs…