-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
emmanuel
committed
May 12, 2017
0 parents
commit 687ee86
Showing
134 changed files
with
5,022 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
*.iml | ||
.gradle | ||
/local.properties | ||
/.idea/workspace.xml | ||
/.idea/libraries | ||
.DS_Store | ||
/build | ||
/captures | ||
.idea |
Empty file.
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 @@ | ||
/build |
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,34 @@ | ||
apply plugin: 'com.android.application' | ||
|
||
android { | ||
compileSdkVersion rootProject.ext.compileSdkVersion | ||
buildToolsVersion rootProject.ext.buildToolsVersion | ||
|
||
defaultConfig { | ||
applicationId "com.adyen.checkout" | ||
minSdkVersion rootProject.ext.minSdkVersion | ||
targetSdkVersion rootProject.ext.targetSdkVersion | ||
versionCode rootProject.ext.versionCode | ||
versionName rootProject.ext.versionName | ||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" | ||
} | ||
buildTypes { | ||
release { | ||
debuggable rootProject.ext.release_debuggable | ||
minifyEnabled rootProject.ext.release_minifyEnabled | ||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' | ||
} | ||
debug { | ||
debuggable rootProject.ext.debug_debuggable | ||
testCoverageEnabled = rootProject.ext.debug_testCoverageEnabled | ||
} | ||
} | ||
|
||
testBuildType rootProject.ext.testBuildType | ||
} | ||
|
||
dependencies { | ||
compile fileTree(include: ['*.jar'], dir: 'libs') | ||
|
||
compile 'com.adyen.checkout:ui:1.0.5' | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Add project specific ProGuard rules here. | ||
# By default, the flags in this file are appended to flags specified | ||
# in /Users/andrei/Library/Android/sdk/tools/proguard/proguard-android.txt | ||
# You can edit the include path and order by changing the proguardFiles | ||
# directive in build.gradle. | ||
# | ||
# For more details, see | ||
# http://developer.android.com/guide/developing/tools/proguard.html | ||
|
||
# Add any project specific keep options here: | ||
|
||
# If your project uses WebView with JS, uncomment the following | ||
# and specify the fully qualified class name to the JavaScript interface | ||
# class: | ||
#-keepclassmembers class fqcn.of.javascript.interface.for.webview { | ||
# public *; | ||
#} |
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,7 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest | ||
xmlns:tools="http://schemas.android.com/tools" | ||
package="com.adyen.checkout"> | ||
|
||
<uses-sdk tools:overrideLibrary="android.support.test.uiautomator.v18"/> | ||
</manifest> |
129 changes: 129 additions & 0 deletions
129
app/src/androidTest/java/com/adyen/checkout/CardNumberService.java
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,129 @@ | ||
package com.adyen.checkout; | ||
|
||
import java.util.ArrayList; | ||
import java.util.Collection; | ||
|
||
/** | ||
* This class provides a list of creditcard numbers that can be used on Test. | ||
* See: https://gist.github.com/j3j5/8b3e48ccad746b90a54a | ||
*/ | ||
|
||
public final class CardNumberService { | ||
|
||
private CardNumberService() { | ||
// Private Constructor | ||
} | ||
|
||
public static Collection<String> getMasterCardNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("5100 0811 1222 3332"); | ||
list.add("5100 2900 2900 2909"); | ||
list.add("5577 0000 5577 0004"); | ||
list.add("5136 3333 3333 3335"); | ||
list.add("5585 5585 5585 5583"); | ||
list.add("5555 4444 3333 1111"); | ||
list.add("5555 5555 5555 4444"); | ||
list.add("5500 0000 0000 0004"); | ||
list.add("5424 0000 0000 0015"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getVISANumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("4111 1111 1111 1111"); | ||
list.add("4988 4388 4388 4305"); | ||
list.add("4166 6766 6766 6746"); | ||
list.add("4646 4646 4646 4644"); | ||
list.add("4444 3333 2222 1111"); | ||
list.add("4400 0000 0000 0008"); | ||
list.add("4977 9494 9494 9497"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getJCBNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("3569 9900 1009 5841"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getCarteBancaireNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("4035 5010 0000 0008"); | ||
list.add("4360 0000 0100 0005"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getAmexNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("3700 0000 0000 002"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getDinersNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("3600 6666 3333 44"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> gerDiscoverNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("6011 6011 6011 6611"); | ||
list.add("6445 6445 6445 6445"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getMaestroNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("6731 0123 4567 8906"); | ||
list.add("6759 6498 2643 8453"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getMisterCashNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("6703 4444 4444 4449"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getHiperCardNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("6062 8288 8866 6688"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getBrazilianCompanyNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("5066 9911 1111 1118"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getDankortNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("5019 5555 4444 5555"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> getUnionPayCreditCardNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("6221 5588 1234 0000"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> get3DSecureNumbers() { | ||
ArrayList<String> list = new ArrayList<>(); | ||
list.add("5212 3456 7890 1234"); | ||
list.add("4212 3456 7890 1237"); | ||
list.add("3451 7792 5488 348"); | ||
list.add("3569 9900 1009 5833"); | ||
return list; | ||
} | ||
|
||
public static Collection<String> removeWhiteSpaces(Collection<String> collection) { | ||
ArrayList<String> result = new ArrayList<>(); | ||
for (String str : collection) { | ||
result.add(str.replaceAll(" ", "")); | ||
} | ||
return result; | ||
} | ||
} | ||
|
26 changes: 26 additions & 0 deletions
26
app/src/androidTest/java/com/adyen/checkout/ExampleInstrumentedTest.java
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,26 @@ | ||
package com.adyen.checkout; | ||
|
||
import android.content.Context; | ||
import android.support.test.InstrumentationRegistry; | ||
import android.support.test.runner.AndroidJUnit4; | ||
|
||
import org.junit.Test; | ||
import org.junit.runner.RunWith; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
/** | ||
* Instrumentation test, which will execute on an Android device. | ||
* | ||
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a> | ||
*/ | ||
@RunWith(AndroidJUnit4.class) | ||
public class ExampleInstrumentedTest { | ||
@Test | ||
public void useAppContext() throws Exception { | ||
// Context of the app under test. | ||
Context appContext = InstrumentationRegistry.getTargetContext(); | ||
|
||
assertEquals("com.adyen.checkout", appContext.getPackageName()); | ||
} | ||
} |
49 changes: 49 additions & 0 deletions
49
app/src/androidTest/java/com/adyen/checkout/IbanNumberService.java
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,49 @@ | ||
package com.adyen.checkout; | ||
|
||
import java.util.ArrayList; | ||
import java.util.Collection; | ||
import java.util.List; | ||
|
||
public final class IbanNumberService { | ||
|
||
public static Collection<String> getIbanNumbers() { | ||
List<String> list = new ArrayList<>(); | ||
list.add("NL13TEST0123456789"); | ||
list.add("NL36TEST0236169114"); | ||
list.add("NL26TEST0336169116"); | ||
list.add("NL16TEST0436169118"); | ||
list.add("NL81TEST0536169128"); | ||
list.add("NL27TEST0636169146"); | ||
list.add("NL39TEST0736169237"); | ||
list.add("NL82TEST0836169255"); | ||
list.add("NL72TEST0936169257"); | ||
list.add("NL46TEST0136169112"); | ||
list.add("NL70TEST0736160337"); | ||
list.add("NL18TEST0736162437"); | ||
list.add("NL92TEST0736163433"); | ||
list.add("DE87123456781234567890"); | ||
list.add("DE92123456789876543210"); | ||
list.add("DE14123456780023456789"); | ||
list.add("DE36444488881234567890"); | ||
list.add("DE41444488889876543210"); | ||
list.add("DE60444488880023456789"); | ||
list.add("DE89888888881234567890"); | ||
list.add("DE94888888889876543210"); | ||
list.add("DE16888888880023456789"); | ||
list.add("IT60X0542811101000000123456"); | ||
list.add("FR1420041010050500013M02606"); | ||
list.add("ES9121000418450200051332"); | ||
list.add("AT151234512345678901"); | ||
list.add("CH4912345123456789012"); | ||
list.add("DK8612341234567890"); | ||
list.add("GB85TEST12345612345678"); | ||
list.add("NO6012341234561"); | ||
list.add("PL20123123411234567890123456"); | ||
list.add("SE9412312345678901234561"); | ||
return list; | ||
} | ||
|
||
private IbanNumberService() { | ||
// Private constructor | ||
} | ||
} |
Oops, something went wrong.