Skip to content

Commit

Permalink
[in_app_purchase] moved android iap unit tests (flutter#3732)
Browse files Browse the repository at this point in the history
  • Loading branch information
renefloor authored Mar 26, 2021
1 parent 1ecc550 commit 5787b35
Show file tree
Hide file tree
Showing 6 changed files with 43 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/in_app_purchase/in_app_purchase/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,17 @@ android {
lintOptions {
disable 'InvalidPackage'
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}

dependencies {
implementation 'androidx.annotation:annotation:1.0.0'
implementation 'com.android.billingclient:billing:3.0.2'
testImplementation 'junit:junit:4.12'
testImplementation 'org.json:json:20180813'
testImplementation 'org.mockito:mockito-core:3.6.0'
androidTestImplementation 'androidx.test:runner:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

package android.text;

public class TextUtils {
public static boolean isEmpty(CharSequence str) {
return str == null || str.length() == 0;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
// Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

package android.util;

public class Log {
public static int d(String tag, String msg) {
System.out.println("DEBUG: " + tag + ": " + msg);
return 0;
}

public static int i(String tag, String msg) {
System.out.println("INFO: " + tag + ": " + msg);
return 0;
}

public static int w(String tag, String msg) {
System.out.println("WARN: " + tag + ": " + msg);
return 0;
}

public static int e(String tag, String msg) {
System.out.println("ERROR: " + tag + ": " + msg);
return 0;
}
}

0 comments on commit 5787b35

Please sign in to comment.