Skip to content

Commit

Permalink
Fake SCIOND: Use MTU of 1472 (#3657)
Browse files Browse the repository at this point in the history
  • Loading branch information
sustrik authored Feb 6, 2020
1 parent dbd6e76 commit 08481a3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go/lib/sciond/fake/fake.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func (p Path) Destination() addr.IA {
}

func (p Path) MTU() uint16 {
return 1500
return 1472
}

func (p Path) Expiry() time.Time {
Expand Down
4 changes: 2 additions & 2 deletions go/lib/sciond/fake/fake_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func TestPaths(t *testing.T) {
assert.Equal(t, fake.DummyPath(), paths[0].Path())
assert.Equal(t, []snet.PathInterface{}, paths[0].Interfaces())
assert.Equal(t, xtest.MustParseIA("1-ff00:0:1"), paths[0].Destination())
assert.Equal(t, uint16(1500), paths[0].MTU())
assert.Equal(t, uint16(1472), paths[0].MTU())
// path valid for more than an hour, but less than three
assert.True(t, paths[0].Expiry().After(time.Now().Add(time.Hour)))
assert.True(t, paths[0].Expiry().Before(time.Now().Add(3*time.Hour)))
Expand All @@ -132,7 +132,7 @@ func TestPaths(t *testing.T) {
assert.Equal(t, fake.DummyPath(), paths[0].Path())
assert.Equal(t, []snet.PathInterface{}, paths[0].Interfaces())
assert.Equal(t, xtest.MustParseIA("2-ff00:0:2"), paths[0].Destination())
assert.Equal(t, uint16(1500), paths[0].MTU())
assert.Equal(t, uint16(1472), paths[0].MTU())
// path valid for more than two hours, but less than four
assert.True(t, paths[0].Expiry().After(time.Now().Add(2*time.Hour)))
assert.True(t, paths[0].Expiry().Before(time.Now().Add(4*time.Hour)))
Expand Down

0 comments on commit 08481a3

Please sign in to comment.