-
Notifications
You must be signed in to change notification settings - Fork 71
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #141 from adjust/v4170
Version 4.17.0
- Loading branch information
Showing
61 changed files
with
808 additions
and
246 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,61 +10,54 @@ public class TestApp : MonoBehaviour | |
public static readonly string TAG = "[TestApp]"; | ||
|
||
#if (UNITY_WSA || UNITY_WP8) | ||
public const string CLIENT_SDK = "[email protected]"; | ||
private const string PORT = ":8080"; | ||
private const string PROTOCOL = "http://"; | ||
private const string BASE_URL = PROTOCOL + "localhost" + PORT; // Windows simulator | ||
private const string BASE_URL = PROTOCOL + "localhost" + PORT; | ||
private const string GDPR_URL = PROTOCOL + "localhost" + PORT; | ||
#elif UNITY_ANDROID | ||
public const string CLIENT_SDK = "[email protected]"; | ||
private const string PORT = ":8443"; | ||
private const string PROTOCOL = "https://"; | ||
private const string BASE_URL = PROTOCOL + "10.0.2.2" + PORT; // Android simulator | ||
private const string BASE_URL = PROTOCOL + "192.168.8.197" + PORT; | ||
private const string GDPR_URL = PROTOCOL + "192.168.8.197" + PORT; | ||
#elif UNITY_IOS | ||
public const string CLIENT_SDK = "[email protected]"; | ||
private const string PORT = ":8080"; | ||
private const string PROTOCOL = "http://"; | ||
private const string BASE_URL = PROTOCOL + "127.0.0.1" + PORT; // iOS simulator | ||
// private const string BASE_URL = PROTOCOL + "192.168.8.141" + PORT; // Over WiFi | ||
|
||
private const string BASE_URL = PROTOCOL + "192.168.8.197" + PORT; | ||
private const string GDPR_URL = PROTOCOL + "192.168.8.197" + PORT; | ||
private TestLibraryiOS _testLibraryiOS; | ||
#else | ||
public const string CLIENT_SDK = null; | ||
#endif | ||
|
||
void OnGUI() | ||
{ | ||
if (GUI.Button(new Rect(0, Screen.height * 0 / 2, Screen.width, Screen.height / 2), "Start test")) | ||
{ | ||
StartTestSession (); | ||
StartTestSession(); | ||
} | ||
} | ||
|
||
private void StartTestSession() | ||
{ | ||
ITestLibrary testLibrary = GetPlatformSpecificTestLibrary (); | ||
|
||
ITestLibrary testLibrary = GetPlatformSpecificTestLibrary(); | ||
#if UNITY_IOS | ||
_testLibraryiOS = testLibrary as TestLibraryiOS; | ||
#endif | ||
// Set specific tests to run. | ||
//testLibrary.AddTest("current/eventBuffering/Test_EventBuffering_sensitive_packets"); | ||
//testLibrary.AddTest("current/gdpr/Test_GdprForgetMe_after_install"); | ||
//testLibrary.AddTestDirectory ("current/deeplink-deferred"); | ||
// testLibrary.AddTest("current/eventBuffering/Test_EventBuffering_sensitive_packets"); | ||
// testLibrary.AddTest("current/gdpr/Test_GdprForgetMe_after_install"); | ||
// testLibrary.AddTestDirectory ("current/deeplink-deferred"); | ||
|
||
Log("Starting test session..."); | ||
Log("Starting test session."); | ||
testLibrary.StartTestSession(); | ||
} | ||
|
||
private ITestLibrary GetPlatformSpecificTestLibrary() | ||
{ | ||
// gdpr url on sdk_test_server is the same as base url | ||
string gdprUrl = BASE_URL; | ||
#if UNITY_IOS | ||
return new TestLibraryiOS(BASE_URL, gdprUrl); | ||
return new TestLibraryiOS(BASE_URL, GDPR_URL); | ||
#elif UNITY_ANDROID | ||
return new TestLibraryAndroid(BASE_URL, gdprUrl); | ||
return new TestLibraryAndroid(BASE_URL, GDPR_URL); | ||
#elif (UNITY_WSA || UNITY_WP8) | ||
return new TestLibraryWindows(BASE_URL, gdprUrl); | ||
return new TestLibraryWindows(BASE_URL, GDPR_URL); | ||
#else | ||
Debug.Log("Cannot run integration tests (Error in TestApp.GetPlatformSpecificTestLibrary(...)). None of the supported platforms selected."); | ||
return null; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using System; | ||
using System.Runtime.InteropServices; | ||
using UnityEngine; | ||
|
||
namespace com.adjust.sdk.imei | ||
{ | ||
#if UNITY_ANDROID | ||
public class AdjustImeiAndroid | ||
{ | ||
private static AndroidJavaClass ajcAdjustImei = new AndroidJavaClass("com.adjust.sdk.imei.AdjustImei"); | ||
|
||
public static void ReadImei() | ||
{ | ||
if (ajcAdjustImei == null) | ||
{ | ||
ajcAdjustImei = new AndroidJavaClass("com.adjust.sdk.Adjust"); | ||
} | ||
ajcAdjustImei.CallStatic("readImei"); | ||
} | ||
|
||
public static void DoNotReadImei() | ||
{ | ||
if (ajcAdjustImei == null) | ||
{ | ||
ajcAdjustImei = new AndroidJavaClass("com.adjust.sdk.Adjust"); | ||
} | ||
ajcAdjustImei.CallStatic("doNotReadImei"); | ||
} | ||
} | ||
#endif | ||
} |
Oops, something went wrong.