mirror of
https://github.com/mas-cli/mas
synced 2024-11-21 19:23:01 +00:00
Improve access control.
Partial #592 Signed-off-by: Ross Goldberg <484615+rgoldberg@users.noreply.github.com>
This commit is contained in:
parent
490ee2d338
commit
586de07389
3 changed files with 5 additions and 5 deletions
|
@ -56,7 +56,7 @@ extension Mas {
|
||||||
/// - appID: App identifier
|
/// - appID: App identifier
|
||||||
/// - appLibrary: Library of installed apps
|
/// - appLibrary: Library of installed apps
|
||||||
/// - Throws: Any error that occurs while attempting to install the app.
|
/// - Throws: Any error that occurs while attempting to install the app.
|
||||||
fileprivate func install(appID: AppID, appLibrary: AppLibrary) throws {
|
private func install(appID: AppID, appLibrary: AppLibrary) throws {
|
||||||
// Try to download applications with given identifiers and collect results
|
// Try to download applications with given identifiers and collect results
|
||||||
if let product = appLibrary.installedApp(withAppID: appID), !force {
|
if let product = appLibrary.installedApp(withAppID: appID), !force {
|
||||||
printWarning("\(product.appName) is already installed")
|
printWarning("\(product.appName) is already installed")
|
||||||
|
|
|
@ -13,15 +13,15 @@ import XCTest
|
||||||
|
|
||||||
class MASErrorTestCase: XCTestCase {
|
class MASErrorTestCase: XCTestCase {
|
||||||
private let errorDomain = "MAS"
|
private let errorDomain = "MAS"
|
||||||
var error: MASError!
|
private var error: MASError!
|
||||||
var nserror: NSError!
|
private var nserror: NSError!
|
||||||
|
|
||||||
/// Convenience property for setting the value which will be use for the localized description
|
/// Convenience property for setting the value which will be use for the localized description
|
||||||
/// value of the next NSError created.
|
/// value of the next NSError created.
|
||||||
///
|
///
|
||||||
/// Only used when the NSError does not have a user info
|
/// Only used when the NSError does not have a user info
|
||||||
/// entry for localized description.
|
/// entry for localized description.
|
||||||
var localizedDescription: String {
|
private var localizedDescription: String {
|
||||||
get { "dummy value" }
|
get { "dummy value" }
|
||||||
set {
|
set {
|
||||||
NSError.setUserInfoValueProvider(forDomain: errorDomain) { _, _ in
|
NSError.setUserInfoValueProvider(forDomain: errorDomain) { _, _ in
|
||||||
|
|
|
@ -11,7 +11,7 @@ import XCTest
|
||||||
@testable import mas
|
@testable import mas
|
||||||
|
|
||||||
class NetworkManagerTests: XCTestCase {
|
class NetworkManagerTests: XCTestCase {
|
||||||
override public func setUp() {
|
override func setUp() {
|
||||||
super.setUp()
|
super.setUp()
|
||||||
Mas.initialize()
|
Mas.initialize()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue