add wrapper for multicast call param
This commit is contained in:
parent
37ee0296ec
commit
c3122702f7
3 changed files with 19 additions and 2 deletions
|
@ -40,6 +40,8 @@ public class Tester {
|
||||||
//Main library
|
//Main library
|
||||||
try {
|
try {
|
||||||
System.loadLibrary("linphone-" + abi);
|
System.loadLibrary("linphone-" + abi);
|
||||||
|
System.loadLibrary("linphone_tester-" + abi);
|
||||||
|
|
||||||
Log.i("LinphoneCoreFactoryImpl","Loading done with " + abi);
|
Log.i("LinphoneCoreFactoryImpl","Loading done with " + abi);
|
||||||
libLoaded=true;
|
libLoaded=true;
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package org.linphone.tester;
|
package org.linphone.tester;
|
||||||
|
|
||||||
|
import org.linphone.core.LinphoneCallParams;
|
||||||
import org.linphone.core.LinphoneCore;
|
import org.linphone.core.LinphoneCore;
|
||||||
import org.linphone.core.LinphoneCoreFactory;
|
import org.linphone.core.LinphoneCoreFactory;
|
||||||
import org.linphone.core.LinphoneCoreListenerBase;
|
import org.linphone.core.LinphoneCoreListenerBase;
|
||||||
|
@ -19,6 +20,7 @@ public class WrapperTester extends AndroidTestCase {
|
||||||
LinphoneCore mCore;
|
LinphoneCore mCore;
|
||||||
@Override
|
@Override
|
||||||
protected void runTest() throws Throwable {
|
protected void runTest() throws Throwable {
|
||||||
|
//multicast begin
|
||||||
mCore.enableAudioMulticast(true);
|
mCore.enableAudioMulticast(true);
|
||||||
Assert.assertEquals(true, mCore.audioMulticastEnabled());
|
Assert.assertEquals(true, mCore.audioMulticastEnabled());
|
||||||
mCore.enableAudioMulticast(false);
|
mCore.enableAudioMulticast(false);
|
||||||
|
@ -29,6 +31,18 @@ public class WrapperTester extends AndroidTestCase {
|
||||||
mCore.enableVideoMulticast(false);
|
mCore.enableVideoMulticast(false);
|
||||||
Assert.assertEquals(false, mCore.videoMulticastEnabled());
|
Assert.assertEquals(false, mCore.videoMulticastEnabled());
|
||||||
|
|
||||||
|
LinphoneCallParams params = mCore.createDefaultCallParameters();
|
||||||
|
params.enableAudioMulticast(true);
|
||||||
|
Assert.assertEquals(true, params.audioMulticastEnabled());
|
||||||
|
params.enableAudioMulticast(false);
|
||||||
|
Assert.assertEquals(false, params.audioMulticastEnabled());
|
||||||
|
|
||||||
|
params.enableVideoMulticast(true);
|
||||||
|
Assert.assertEquals(true, params.videoMulticastEnabled());
|
||||||
|
params.enableVideoMulticast(false);
|
||||||
|
Assert.assertEquals(false, params.videoMulticastEnabled());
|
||||||
|
|
||||||
|
|
||||||
String ip = "224.3.2.1";
|
String ip = "224.3.2.1";
|
||||||
mCore.setAudioMulticastAddr(ip);
|
mCore.setAudioMulticastAddr(ip);
|
||||||
Assert.assertEquals(ip, mCore.getAudioMulticastAddr());
|
Assert.assertEquals(ip, mCore.getAudioMulticastAddr());
|
||||||
|
@ -42,6 +56,7 @@ public class WrapperTester extends AndroidTestCase {
|
||||||
|
|
||||||
mCore.setVideoMulticastTtl(4);
|
mCore.setVideoMulticastTtl(4);
|
||||||
Assert.assertEquals(4, mCore.getVideoMulticastTtl());
|
Assert.assertEquals(4, mCore.getVideoMulticastTtl());
|
||||||
|
//multicast end
|
||||||
|
|
||||||
//Test setPrimaryContact
|
//Test setPrimaryContact
|
||||||
String address = "Linphone Android <sip:linphone.android@unknown-host>";
|
String address = "Linphone Android <sip:linphone.android@unknown-host>";
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 3b9a717089de8d5ff5412021b2ce194c66013443
|
Subproject commit 38ff54a6bf747b07e3062de6af02d066ba66ca87
|
Loading…
Reference in a new issue