Skip to content

Commit

Permalink
More Mocks
Browse files Browse the repository at this point in the history
ibeacon
image-resizer
in-app-purchase
insomnia
instagram
intel-security
intercom
is-debug
jins-meme
keychain
launch-navigator
launch-review
linkedin
location-accuracy
  • Loading branch information
chrisgriffith committed Jul 19, 2017
1 parent 3122773 commit 79bc816
Show file tree
Hide file tree
Showing 45 changed files with 5,232 additions and 17 deletions.
88 changes: 86 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,25 +7,109 @@ Ionic Native wraps plugin callbacks in a Promise or Observable, providing a comm
However, once you integrate these plugins into your Ionic application, use of a device or emulator is required for development and testing which can slow your workflow.

## Currently Available Mocks
- actions-sheets
- actions-sheet
- admob-free
- admob-pro
- alipay
- android-fingerprint-auth
- android-full-screen
- android-permissions
- app-availability
- app-minimize
- app-preferences
- app-rate
- app-update
- app-version
- appodeal
- autostart
- background-fetch
- background-geolocation
- background-mode
- backlight
- badge
- barcode-scanner
- base64
- base64-to-gallery
- battery-status
- ble
- bluetooth-serial
- brightness
- broadcaster
- browser-tab
- calendar
- call-number
- camera
- camera-preview
- card-io
- clipboard
- code-push
- contacts
- core
- couchbase-lite
- crop
- date-picker
- db-meter
- deeplinks
- device
- device-accounts
- device-feedback
- device-motion
- device-orientation
- device
- dialog
- document-viewer
- email-composer
- estimote-beacons
- facebook
- fcm
- file
- file-chooser
- file-encryption
- file-opener
- file-path
- file-transfer
- fingerprint-aio
- firebase
- firebase-analytics
- firebase-dynamic-links
- flashlight
- flurry-analytics
- ftp
- geofence
- geolocation
- globalization
- google-analytics
- google-plus
- gyroscope
- header-color
- health
- health-kit
- hotspot
- http
- httpd
- ibeacon
- image-picker
- image-resizer
- in-app-browser
- in-app-purchase
- insomnia
- instagram
- intel-security
- intercom
- is-debug
- jins-meme
- keyboard
- keychain
- launch-navigator
- launch-review
- linkedin
- local-notifications
- location-accuracy
- media
- network
- phonegap-local-notification
- push
- screen-orientation
- secure-storage
- social-sharing
- splash-screen
- sqlite
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ionic-native-mocks",
"version": "2.0.0",
"version": "2.0.1",
"description": "Mocks for Ionic Native for Cordova and Ionic with TypeScript, ES6+, Promise and Observable support",
"homepage": "https://ionicframework.com/",
"author": "Chris Griffith <[email protected]> (https://aj-sofwtare.com)",
Expand Down
14 changes: 7 additions & 7 deletions src/@ionic-native-mocks/plugins/android-full-screen/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { AndroidFullScreen } from '@ionic-native/android-full-screen';
export class AndroidFullScreenMock extends AndroidFullScreen {
/**
* Is this plugin supported?
* @return {Promise<void>}
* @return {Promise<any>}
*/
isSupported(): Promise<any> {
return new Promise((resolve, reject) => {
Expand All @@ -13,7 +13,7 @@ export class AndroidFullScreenMock extends AndroidFullScreen {

/**
* Is immersive mode supported?
* @return {Promise<void>}
* @return {Promise<any>}
*/
isImmersiveModeSupported(): Promise<any> {
return new Promise((resolve, reject) => {
Expand Down Expand Up @@ -42,7 +42,7 @@ export class AndroidFullScreenMock extends AndroidFullScreen {
};
/**
* Hide system UI until user interacts.
* @return {Promise<void>}
* @return {Promise<any>}
*/
leanMode(): Promise<any> {
return new Promise((resolve, reject) => {
Expand All @@ -51,7 +51,7 @@ export class AndroidFullScreenMock extends AndroidFullScreen {
};
/**
* Show system UI.
* @return {Promise<void>}
* @return {Promise<any>}
*/
showSystemUI(): Promise<any> {
return new Promise((resolve, reject) => {
Expand All @@ -60,7 +60,7 @@ export class AndroidFullScreenMock extends AndroidFullScreen {
};
/**
* Extend your app underneath the status bar (Android 4.4+ only).
* @return {Promise<void>}
* @return {Promise<any>}
*/
showUnderStatusBar(): Promise<any> {
return new Promise((resolve, reject) => {
Expand All @@ -69,7 +69,7 @@ export class AndroidFullScreenMock extends AndroidFullScreen {
};
/**
* Extend your app underneath the system UI (Android 4.4+ only).
* @return {Promise<void>}
* @return {Promise<any>}
*/
showUnderSystemUI(): Promise<any> {
return new Promise((resolve, reject) => {
Expand All @@ -78,7 +78,7 @@ export class AndroidFullScreenMock extends AndroidFullScreen {
};
/**
* Hide system UI and keep it hidden (Android 4.4+ only).
* @return {Promise<void>}
* @return {Promise<any>}
*/
immersiveMode(): Promise<any> {
return new Promise((resolve, reject) => {
Expand Down
2 changes: 1 addition & 1 deletion src/@ionic-native-mocks/plugins/ble/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ export class BLEMock extends BLE {
/**
* Report if bluetooth is enabled.
*
* @returns {Promise<void>} Returns a Promise that resolves if Bluetooth is enabled, and rejects if disabled.
* @returns {Promise<any>} Returns a Promise that resolves if Bluetooth is enabled, and rejects if disabled.
*/
isEnabled(): Promise<any> {
return new Promise((resolve, reject) => {
Expand Down
8 changes: 4 additions & 4 deletions src/@ionic-native-mocks/plugins/code-push/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -291,15 +291,15 @@ export class CodePushMock extends CodePush {
*
* @param notifySucceeded Optional callback invoked if the plugin was successfully notified.
* @param notifyFailed Optional callback invoked in case of an error during notifying the plugin.
* @returns {Promise<void>}
* @returns {Promise<any>}
*/
notifyApplicationReady(): Promise<void> { return; };
notifyApplicationReady(): Promise<any> { return; };
/**
* Reloads the application. If there is a pending update package installed using ON_NEXT_RESTART or ON_NEXT_RESUME modes, the update
* will be immediately visible to the user. Otherwise, calling this function will simply reload the current version of the application.
* @returns {Promise<void>}
* @returns {Promise<any>}
*/
restartApplication(): Promise<void> { return; };
restartApplication(): Promise<any> { return; };
/**
* Convenience method for installing updates in one method call.
* This method is provided for simplicity, and its behavior can be replicated by using window.codePush.checkForUpdate(), RemotePackage's download() and LocalPackage's install() methods.
Expand Down
Loading

0 comments on commit 79bc816

Please sign in to comment.