2017-11-08 08:28:03 +00:00
|
|
|
package torrent
|
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
|
|
|
"github.com/anacrolix/missinggo"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
|
|
)
|
|
|
|
|
|
|
|
func TestDefaultExtensionBytes(t *testing.T) {
|
|
|
|
var pex peerExtensionBytes
|
2018-02-03 02:36:17 +00:00
|
|
|
missinggo.CopyExact(&pex, defaultPeerExtensionBytes())
|
2017-11-08 08:28:03 +00:00
|
|
|
assert.True(t, pex.SupportsDHT())
|
|
|
|
assert.True(t, pex.SupportsExtended())
|
|
|
|
assert.False(t, pex.SupportsFast())
|
|
|
|
}
|