Merged master --> 2.4.x.
diff --git a/README.md b/README.md
index f2b4562..436eefd 100644
--- a/README.md
+++ b/README.md
@@ -21,9 +21,9 @@
 #         under the License.
 -->
 
-|Android|iOS| Windows 8.1 Store | Windows 8.1 Phone | Windows 10 Store | Travis CI |
-|:-:|:-:|:-:|:-:|:-:|:-:|
-|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=android,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=android,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=ios,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=ios,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=windows-8.1-store,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=windows-8.1-store,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=windows-8.1-phone,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=windows-8.1-phone,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=windows-10-store,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=windows-10-store,PLUGIN=cordova-plugin-camera/)|[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg?branch=master)](https://travis-ci.org/apache/cordova-plugin-camera)
+|Android 4.4|Android 5.1|Android 6.0|iOS 9.3|iOS 10.0|Windows 10 Store|Travis CI|
+|:-:|:-:|:-:|:-:|:-:|:-:|:-:|
+|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=android-4.4,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=android-4.4,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=android-5.1,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=android-5.1,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=android-6.0,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=android-6.0,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=ios-9.3,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=ios-9.3,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=ios-10.0,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=ios-10.0,PLUGIN=cordova-plugin-camera/)|[![Build Status](http://cordova-ci.cloudapp.net:8080/buildStatus/icon?job=cordova-periodic-build/PLATFORM=windows-10-store,PLUGIN=cordova-plugin-camera)](http://cordova-ci.cloudapp.net:8080/job/cordova-periodic-build/PLATFORM=windows-10-store,PLUGIN=cordova-plugin-camera/)|[![Build Status](https://travis-ci.org/apache/cordova-plugin-camera.svg?branch=master)](https://travis-ci.org/apache/cordova-plugin-camera)
 
 # cordova-plugin-camera
 
diff --git a/RELEASENOTES.md b/RELEASENOTES.md
index 001470e..cbb782c 100644
--- a/RELEASENOTES.md
+++ b/RELEASENOTES.md
@@ -20,6 +20,13 @@
 -->
 # Release Notes
 
+### 2.4.1 (Apr 27, 2017)
+* [CB-12622](https://issues.apache.org/jira/browse/CB-12622) Updated build badges in `README`
+* [CB-12650](https://issues.apache.org/jira/browse/CB-12650) Fix manual test for uploading image
+* [CB-12685](https://issues.apache.org/jira/browse/CB-12685) added `package.json` to tests folder
+* [CB-12622](https://issues.apache.org/jira/browse/CB-12622) (android) Appium tests: Bust **Android** 6 and 7 permission dialogs
+* [CB-12618](https://issues.apache.org/jira/browse/CB-12618) (android) Appium tests: Handle native cling
+
 ### 2.4.0 (Feb 28, 2017)
 * [CB-12501](https://issues.apache.org/jira/browse/CB-12501) **Android**: Appium tests don't use `XPath` selectors anymore
 * [CB-12469](https://issues.apache.org/jira/browse/CB-12469) Appium tests can now run on **iOS 10**
diff --git a/appium-tests/android/android.spec.js b/appium-tests/android/android.spec.js
index 6b259c3..69f7e35 100644
--- a/appium-tests/android/android.spec.js
+++ b/appium-tests/android/android.spec.js
@@ -225,6 +225,40 @@
             })
             .waitForDeviceReady()
             .injectLibraries()
+            .then(function () {
+                var options = {
+                    quality: 50,
+                    allowEdit: false,
+                    sourceType: cameraConstants.PictureSourceType.SAVEDPHOTOALBUM,
+                    saveToPhotoAlbum: false,
+                    targetWidth: 210,
+                    targetHeight: 210
+                };
+                return driver
+                    .then(function () { return getPicture(options, true); })
+                    .context(CONTEXT_NATIVE_APP)
+                    // case insensitive select, will be handy with Android 7 support
+                    .elementByXPath('//android.widget.Button[translate(@text, "alow", "ALOW")="ALLOW"]')
+                    .click()
+                    .fail(function noAlert() { })
+                    .deviceKeyEvent(BACK_BUTTON)
+                    .sleep(2000)
+                    .elementById('action_bar_title')
+                    .then(function () {
+                        // success means we're still in native app
+                        return driver
+                            .deviceKeyEvent(BACK_BUTTON);
+                        }, function () {
+                            // error means we're already in webview
+                            return driver;
+                        });
+            })
+            .then(function () {
+                // doing it inside a function because otherwise 
+                // it would not hook up to the webviewContext var change
+                // in the first methods of this chain
+                return driver.context(webviewContext);
+            })
             .deleteFillerImage(fillerImagePath)
             .then(function () {
                 fillerImagePath = null;
@@ -291,6 +325,7 @@
             pending('This test requires a functioning camera on the Android device/emulator, and this test suite\'s functional camera test failed on your target environment.');
         }
     }
+
     afterAll(function (done) {
         checkSession(done);
         driver
@@ -390,7 +425,7 @@
                         return driver
                             .elementByAndroidUIAutomator('new UiSelector().text("Choose video")')
                             .fail(function () {
-                                throw 'Couldn\'t find "Choose video" element.';
+                                throw 'Couldn\'t find a "Choose video" element.';
                             });
                     })
                     .deviceKeyEvent(BACK_BUTTON)
@@ -610,6 +645,15 @@
                 .deviceKeyEvent(BACK_BUTTON)
                 .elementById('Apps')
                 .click()
+                .then(function () {
+                    return driver
+                        .elementByXPath('//android.widget.Button[@text="OK"]')
+                        .click()
+                        .fail(function () {
+                            // no cling is all right
+                            // it is not a brand new emulator, then
+                        });
+                })
                 .elementByAndroidUIAutomator('new UiSelector().text("Gallery")')
                 .click()
                 .elementByAndroidUIAutomator('new UiSelector().textContains("Pictures")')
diff --git a/appium-tests/helpers/cameraHelper.js b/appium-tests/helpers/cameraHelper.js
index a16916f..caf0f9e 100644
--- a/appium-tests/helpers/cameraHelper.js
+++ b/appium-tests/helpers/cameraHelper.js
@@ -169,6 +169,7 @@
                 return;
             }
         }
+
         try {
             if (result.indexOf('file:') === 0 ||
                 result.indexOf('content:') === 0 ||
@@ -184,6 +185,8 @@
                     } else {
                         verifyFile(entry);
                     }
+                }, function (err) {
+                    errorCallback(err);
                 });
             } else {
                 displayImage(result);
diff --git a/package.json b/package.json
index 4bac73c..18e18ed 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "cordova-plugin-camera",
-  "version": "2.4.0",
+  "version": "2.4.1",
   "description": "Cordova Camera Plugin",
   "types": "./types/index.d.ts",
   "cordova": {
diff --git a/plugin.xml b/plugin.xml
index 1450f41..7ae0041 100644
--- a/plugin.xml
+++ b/plugin.xml
@@ -22,7 +22,7 @@
     xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:rim="http://www.blackberry.com/ns/widgets"
     id="cordova-plugin-camera"
-    version="2.4.0">
+    version="2.4.1">
     <name>Camera</name>
     <description>Cordova Camera Plugin</description>
     <license>Apache 2.0</license>
diff --git a/tests/package.json b/tests/package.json
new file mode 100644
index 0000000..646e22c
--- /dev/null
+++ b/tests/package.json
@@ -0,0 +1,14 @@
+{
+  "name": "cordova-plugin-camera-tests",
+  "version": "2.4.1-dev",
+  "description": "",
+  "cordova": {
+    "id": "cordova-plugin-camera-tests",
+    "platforms": []
+  },
+  "keywords": [
+    "ecosystem:cordova"
+  ],
+  "author": "",
+  "license": "Apache 2.0"
+}
diff --git a/tests/plugin.xml b/tests/plugin.xml
index fcb2a90..073ef28 100644
--- a/tests/plugin.xml
+++ b/tests/plugin.xml
@@ -22,11 +22,11 @@
     xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:rim="http://www.blackberry.com/ns/widgets"
     id="cordova-plugin-camera-tests"
-    version="2.4.0">
+    version="2.4.1">
     <name>Cordova Camera Plugin Tests</name>
     <license>Apache 2.0</license>
 
-    <dependency id="cordova-plugin-file" version=">=2.0.0" />
+    <dependency id="cordova-plugin-file-transfer" />
 
     <js-module src="tests.js" name="tests">
     </js-module>
diff --git a/tests/tests.js b/tests/tests.js
index 222a839..0c85188 100644
--- a/tests/tests.js
+++ b/tests/tests.js
@@ -177,7 +177,7 @@
         ft.onprogress = function (progressEvent) {
             console.log('progress: ' + progressEvent.loaded + ' of ' + progressEvent.total);
         };
-        var server = "http://cordova-filetransfer.jitsu.com";
+        var server = "http://sheltered-retreat-43956.herokuapp.com";
 
         ft.upload(pictureUrl, server + '/upload', win, fail, options);
         function win(information_back) {