Make data message naming a bit more consistent. (#4177)
* Make data message naming a bit more consistent. OnDataPacket and OnDataMessage half-way in the chain made it confusing (for me at least). Use same name throughout. API still uses SendDataPacket, but that is not harder to read. * test
This commit is contained in:
@@ -645,7 +645,7 @@ func TestDataChannel(t *testing.T) {
|
||||
}
|
||||
|
||||
encoded, _ := proto.Marshal(packetExp)
|
||||
lpl.OnDataPacket(p, packet.Kind, packet)
|
||||
lpl.OnDataMessage(p, packet.Kind, packet)
|
||||
|
||||
// ensure everyone has received the packet
|
||||
for _, op := range participants {
|
||||
@@ -695,7 +695,7 @@ func TestDataChannel(t *testing.T) {
|
||||
}
|
||||
|
||||
encoded, _ := proto.Marshal(packetExp)
|
||||
lpl.OnDataPacket(p, packet.Kind, packet)
|
||||
lpl.OnDataMessage(p, packet.Kind, packet)
|
||||
|
||||
// only p1 should receive the data
|
||||
for _, op := range participants {
|
||||
@@ -729,7 +729,7 @@ func TestDataChannel(t *testing.T) {
|
||||
}
|
||||
if p.CanPublishData() {
|
||||
lpl := rm.LocalParticipantListener()
|
||||
lpl.OnDataPacket(p, packet.Kind, &packet)
|
||||
lpl.OnDataMessage(p, packet.Kind, &packet)
|
||||
}
|
||||
|
||||
// no one should've been sent packet
|
||||
|
||||
Reference in New Issue
Block a user