Comparing version 1.8.0-beta to 1.8.1-beta
{ | ||
"name": "code-push", | ||
"version": "1.8.0-beta", | ||
"version": "1.8.1-beta", | ||
"description": "Management SDK for the CodePush service", | ||
@@ -5,0 +5,0 @@ "main": "script/index.js", |
@@ -70,6 +70,8 @@ # CodePush Management SDK (Node.js) | ||
- __promote(appName: string, sourceDeploymentName: string, destDeploymentName: string): Promise<void>__ - Promotes the latest release from one deployment to another for the specified app. | ||
- __patchRelease(appName: string, deploymentName: string, label: string, updateMetadata: PackageInfo): Promise<void>__ - Updates the specified release's metadata with the given information. | ||
- __release(appName: string, deploymentName: string, updateContentsPath: string, targetBinaryVersion: string, description?: string, isMandatory: boolean = false): Promise<void>__ - Releases a new update to the specified deployment. | ||
- __promote(appName: string, sourceDeploymentName: string, destinationDeploymentName: string, updateMetadata: PackageInfo): Promise<void>__ - Promotes the latest release from one deployment to another for the specified app and updates the release with the given metadata. | ||
- __release(appName: string, deploymentName: string, updateContentsPath: string, targetBinaryVersion: string, updateMetadata: PackageInfo): Promise<void>__ - Releases a new update to the specified deployment with the given metadata. | ||
- __removeAccessKey(accessKey: string): Promise<void>__ - Removes the specified access key from your CodePush account. | ||
@@ -89,2 +91,2 @@ | ||
- __transferApp(appName: string, email: string): Promise<void>__ - Transfers the ownership of the specified app to the specified account. | ||
- __transferApp(appName: string, email: string): Promise<void>__ - Transfers the ownership of the specified app to the specified account. |
@@ -57,4 +57,12 @@ /// <reference path="../definitions/harness.d.ts" /> | ||
} | ||
else if (updateInfo.updateAppVersion) { | ||
callback(null, { updateAppVersion: true, appVersion: updateInfo.appVersion }); | ||
else if (updateInfo.updateAppVersion || updateInfo.shouldRunBinaryVersion) { | ||
var returnUpdateInfo = {}; | ||
if (updateInfo.shouldRunBinaryVersion) { | ||
returnUpdateInfo.shouldRunBinaryVersion = true; | ||
} | ||
if (updateInfo.updateAppVersion) { | ||
returnUpdateInfo.updateAppVersion = true; | ||
returnUpdateInfo.appVersion = updateInfo.appVersion; | ||
} | ||
callback(null, returnUpdateInfo); | ||
return; | ||
@@ -61,0 +69,0 @@ } |
@@ -77,2 +77,22 @@ /// <reference path="../definitions/harness.d.ts" /> | ||
}); | ||
it("SDK forwards shouldRunBinaryVersion notification", function (done) { | ||
mockApi.latestPackage.shouldRunBinaryVersion = true; | ||
var acquisition = new acquisitionSdk.AcquisitionManager(new mockApi.HttpRequester(), configuration); | ||
acquisition.queryUpdateWithCurrentPackage(clone(templateCurrentPackage), function (error, returnPackage) { | ||
assert.equal(null, error); | ||
assert.deepEqual({ shouldRunBinaryVersion: true }, returnPackage); | ||
done(); | ||
}); | ||
}); | ||
it("Package with lower native version gives update notification together with shouldRunBinaryVersion notification", function (done) { | ||
mockApi.latestPackage.shouldRunBinaryVersion = true; | ||
var lowerAppVersionPackage = clone(templateCurrentPackage); | ||
lowerAppVersionPackage.appVersion = "0.0.1"; | ||
var acquisition = new acquisitionSdk.AcquisitionManager(new mockApi.HttpRequester(), configuration); | ||
acquisition.queryUpdateWithCurrentPackage(lowerAppVersionPackage, function (error, returnPackage) { | ||
assert.equal(null, error); | ||
assert.deepEqual(nativeUpdateResult, returnPackage); | ||
done(); | ||
}); | ||
}); | ||
it("Package with higher native version gives no update", function (done) { | ||
@@ -79,0 +99,0 @@ var higherAppVersionPackage = clone(templateCurrentPackage); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
91
1
0
59727
11
1199