@@ -9,7 +9,7 @@ describe('uri-to-multiaddr', () => {
9
9
[ '/ip6/fc00::/tcp/80/http' , 'http://[fc00::]' ] ,
10
10
[ '/ip4/0.0.7.6/tcp/1234' , 'tcp://0.0.7.6:1234' ] ,
11
11
[ '/ip4/0.0.7.6/tcp/1234/http' , 'http://0.0.7.6:1234' ] ,
12
- [ '/ip4/0.0.7.6/tcp/1234/https ' , 'https://0.0.7.6:1234' ] ,
12
+ [ '/ip4/0.0.7.6/tcp/1234/tls/http ' , 'https://0.0.7.6:1234' ] ,
13
13
[ '/ip6/::/tcp/0' , 'tcp://[::]:0' ] ,
14
14
[ '/ip4/0.0.7.6/udp/1234' , 'udp://0.0.7.6:1234' ] ,
15
15
[ '/ip6/::/udp/0' , 'udp://[::]:0' ] ,
@@ -33,14 +33,14 @@ describe('uri-to-multiaddr', () => {
33
33
[ '/dnsaddr/protocol.ai/tcp/80/http' , 'http://protocol.ai:80' , {
34
34
defaultDnsType : 'dnsaddr'
35
35
} ] ,
36
- [ '/dns/protocol.ai/tcp/80/https ' , 'https://protocol.ai:80' ] ,
37
- [ '/dns4/protocol.ai/tcp/80/https ' , 'https://protocol.ai:80' , {
36
+ [ '/dns/protocol.ai/tcp/80/tls/http ' , 'https://protocol.ai:80' ] ,
37
+ [ '/dns4/protocol.ai/tcp/80/tls/http ' , 'https://protocol.ai:80' , {
38
38
defaultDnsType : 'dns4'
39
39
} ] ,
40
- [ '/dns6/protocol.ai/tcp/80/https ' , 'https://protocol.ai:80' , {
40
+ [ '/dns6/protocol.ai/tcp/80/tls/http ' , 'https://protocol.ai:80' , {
41
41
defaultDnsType : 'dns6'
42
42
} ] ,
43
- [ '/dnsaddr/protocol.ai/tcp/80/https ' , 'https://protocol.ai:80' , {
43
+ [ '/dnsaddr/protocol.ai/tcp/80/tls/http ' , 'https://protocol.ai:80' , {
44
44
defaultDnsType : 'dnsaddr'
45
45
} ] ,
46
46
[ '/dns/ipfs.io/tcp/80/ws' , 'ws://ipfs.io' ] ,
@@ -53,14 +53,14 @@ describe('uri-to-multiaddr', () => {
53
53
[ '/dnsaddr/ipfs.io/tcp/80/ws' , 'ws://ipfs.io' , {
54
54
defaultDnsType : 'dnsaddr'
55
55
} ] ,
56
- [ '/dns/ipfs.io/tcp/443/wss ' , 'wss://ipfs.io' ] ,
57
- [ '/dns4/ipfs.io/tcp/443/wss ' , 'wss://ipfs.io' , {
56
+ [ '/dns/ipfs.io/tcp/443/tls/ws ' , 'wss://ipfs.io' ] ,
57
+ [ '/dns4/ipfs.io/tcp/443/tls/ws ' , 'wss://ipfs.io' , {
58
58
defaultDnsType : 'dns4'
59
59
} ] ,
60
- [ '/dns6/ipfs.io/tcp/443/wss ' , 'wss://ipfs.io' , {
60
+ [ '/dns6/ipfs.io/tcp/443/tls/ws ' , 'wss://ipfs.io' , {
61
61
defaultDnsType : 'dns6'
62
62
} ] ,
63
- [ '/dnsaddr/ipfs.io/tcp/443/wss ' , 'wss://ipfs.io' , {
63
+ [ '/dnsaddr/ipfs.io/tcp/443/tls/ws ' , 'wss://ipfs.io' , {
64
64
defaultDnsType : 'dnsaddr'
65
65
} ] ,
66
66
[ '/dns/ipfs.io/tcp/80/http' , 'http://ipfs.io' ] ,
@@ -73,24 +73,24 @@ describe('uri-to-multiaddr', () => {
73
73
[ '/dnsaddr/ipfs.io/tcp/80/http' , 'http://ipfs.io' , {
74
74
defaultDnsType : 'dnsaddr'
75
75
} ] ,
76
- [ '/dns/ipfs.io/tcp/443/https ' , 'https://ipfs.io' ] ,
77
- [ '/dns4/ipfs.io/tcp/443/https ' , 'https://ipfs.io' , {
76
+ [ '/dns/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io' ] ,
77
+ [ '/dns4/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io' , {
78
78
defaultDnsType : 'dns4'
79
79
} ] ,
80
- [ '/dns6/ipfs.io/tcp/443/https ' , 'https://ipfs.io' , {
80
+ [ '/dns6/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io' , {
81
81
defaultDnsType : 'dns6'
82
82
} ] ,
83
- [ '/dnsaddr/ipfs.io/tcp/443/https ' , 'https://ipfs.io' , {
83
+ [ '/dnsaddr/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io' , {
84
84
defaultDnsType : 'dnsaddr'
85
85
} ] ,
86
- [ '/dns/ipfs.io/tcp/443/https ' , 'https://ipfs.io:443' ] ,
87
- [ '/dns4/ipfs.io/tcp/443/https ' , 'https://ipfs.io:443' , {
86
+ [ '/dns/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io:443' ] ,
87
+ [ '/dns4/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io:443' , {
88
88
defaultDnsType : 'dns4'
89
89
} ] ,
90
- [ '/dns6/ipfs.io/tcp/443/https ' , 'https://ipfs.io:443' , {
90
+ [ '/dns6/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io:443' , {
91
91
defaultDnsType : 'dns6'
92
92
} ] ,
93
- [ '/dnsaddr/ipfs.io/tcp/443/https ' , 'https://ipfs.io:443' , {
93
+ [ '/dnsaddr/ipfs.io/tcp/443/tls/http ' , 'https://ipfs.io:443' , {
94
94
defaultDnsType : 'dnsaddr'
95
95
} ] ,
96
96
[ '/dns/ipfs.io/tcp/443' , 'tcp://ipfs.io:443' ] ,
@@ -114,18 +114,18 @@ describe('uri-to-multiaddr', () => {
114
114
defaultDnsType : 'dnsaddr'
115
115
} ] ,
116
116
[ '/ip4/1.2.3.4/tcp/3456/ws' , 'ws://1.2.3.4:3456' ] ,
117
- [ '/ip4/1.2.3.4/tcp/3456/wss ' , 'wss://1.2.3.4:3456' ] ,
117
+ [ '/ip4/1.2.3.4/tcp/3456/tls/ws ' , 'wss://1.2.3.4:3456' ] ,
118
118
[ '/ip6/::/tcp/0/ws' , 'ws://[::]:0' ] ,
119
- [ '/ip4/1.2.3.4/tcp/3456/wss ' , 'wss://1.2.3.4:3456' ] ,
120
- [ '/ip6/::/tcp/0/wss ' , 'wss://[::]:0' ] ,
121
- [ '/dns/example.com/tcp/443/wss /http-path/foo' , 'wss://example.com:443/foo' ] ,
122
- [ '/dns4/example.com/tcp/443/wss /http-path/foo' , 'wss://example.com:443/foo' , {
119
+ [ '/ip4/1.2.3.4/tcp/3456/tls/ws ' , 'wss://1.2.3.4:3456' ] ,
120
+ [ '/ip6/::/tcp/0/tls/ws ' , 'wss://[::]:0' ] ,
121
+ [ '/dns/example.com/tcp/443/tls/ws /http-path/foo' , 'wss://example.com:443/foo' ] ,
122
+ [ '/dns4/example.com/tcp/443/tls/ws /http-path/foo' , 'wss://example.com:443/foo' , {
123
123
defaultDnsType : 'dns4'
124
124
} ] ,
125
- [ '/dns6/example.com/tcp/443/wss /http-path/foo' , 'wss://example.com:443/foo' , {
125
+ [ '/dns6/example.com/tcp/443/tls/ws /http-path/foo' , 'wss://example.com:443/foo' , {
126
126
defaultDnsType : 'dns6'
127
127
} ] ,
128
- [ '/dnsaddr/example.com/tcp/443/wss /http-path/foo' , 'wss://example.com:443/foo' , {
128
+ [ '/dnsaddr/example.com/tcp/443/tls/ws /http-path/foo' , 'wss://example.com:443/foo' , {
129
129
defaultDnsType : 'dnsaddr'
130
130
} ]
131
131
]
@@ -143,7 +143,7 @@ describe('uri-to-multiaddr', () => {
143
143
const data : Array < [ string , string , MultiaddrFromUriOpts ] > = [
144
144
[ '/dns4/protocol.ai/tcp/80' , 'tcp://protocol.ai:80' , { defaultDnsType : 'dns4' } ] ,
145
145
[ '/dns6/protocol.ai/tcp/80/http' , 'http://protocol.ai:80' , { defaultDnsType : 'dns6' } ] ,
146
- [ '/dnsaddr/protocol.ai/tcp/80/https ' , 'https://protocol.ai:80' , { defaultDnsType : 'dnsaddr' } ]
146
+ [ '/dnsaddr/protocol.ai/tcp/80/tls/http ' , 'https://protocol.ai:80' , { defaultDnsType : 'dnsaddr' } ]
147
147
]
148
148
149
149
data . forEach ( d => {
0 commit comments