diff --git a/AMM.xcodeproj/project.pbxproj b/AMM.xcodeproj/project.pbxproj index 5258e7e..f9eb7d4 100644 --- a/AMM.xcodeproj/project.pbxproj +++ b/AMM.xcodeproj/project.pbxproj @@ -12,7 +12,6 @@ 2E02C97E1E4392C100A6272D /* AMMConstants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E02C97D1E4392C100A6272D /* AMMConstants.swift */; }; 2E03C1751E3EE3B100E8BE9E /* TaskMenuItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E03C1741E3EE3B100E8BE9E /* TaskMenuItem.swift */; }; 2E03C17B1E40870500E8BE9E /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2E03C17A1E40870500E8BE9E /* Assets.xcassets */; }; - 2E045E501E3CB39B0079EE52 /* Aria2Tests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E045E4F1E3CB39B0079EE52 /* Aria2Tests.swift */; }; 2E1195891F4BD34800A7AB81 /* SelectServerWindowController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E1195871F4BD34800A7AB81 /* SelectServerWindowController.swift */; }; 2E11958A1F4BD34800A7AB81 /* SelectServerWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 2E1195881F4BD34800A7AB81 /* SelectServerWindowController.xib */; }; 2E11958C1F4C7B7800A7AB81 /* UIHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E11958B1F4C7B7800A7AB81 /* UIHelper.swift */; }; @@ -34,7 +33,6 @@ 2E468AAC1E39B123009C6CA3 /* Aria2Task.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E468AAB1E39B123009C6CA3 /* Aria2Task.swift */; }; 2E468AAE1E39BA45009C6CA3 /* Aria2Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E468AAD1E39BA45009C6CA3 /* Aria2Constants.swift */; }; 2E5DC59C1E69879600184E0B /* ResizableTabViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E5DC59B1E69879600184E0B /* ResizableTabViewController.swift */; }; - 2E644A551E41B24D00C6347C /* ServerProfileTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E644A541E41B24D00C6347C /* ServerProfileTests.swift */; }; 2E644A611E422B1D00C6347C /* ServerProfileArrayController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E644A601E422B1D00C6347C /* ServerProfileArrayController.swift */; }; 2E644A641E42CDD700C6347C /* ServerProfileMenuItemViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E644A621E42CDD700C6347C /* ServerProfileMenuItemViewController.swift */; }; 2E644A671E42DE4200C6347C /* Aria2Stat.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2E644A661E42DE4200C6347C /* Aria2Stat.swift */; }; @@ -86,7 +84,6 @@ 2E02C97D1E4392C100A6272D /* AMMConstants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AMMConstants.swift; sourceTree = ""; }; 2E03C1741E3EE3B100E8BE9E /* TaskMenuItem.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TaskMenuItem.swift; sourceTree = ""; }; 2E03C17A1E40870500E8BE9E /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; - 2E045E4F1E3CB39B0079EE52 /* Aria2Tests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Aria2Tests.swift; sourceTree = ""; }; 2E1195871F4BD34800A7AB81 /* SelectServerWindowController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SelectServerWindowController.swift; sourceTree = ""; }; 2E1195881F4BD34800A7AB81 /* SelectServerWindowController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SelectServerWindowController.xib; sourceTree = ""; }; 2E11958B1F4C7B7800A7AB81 /* UIHelper.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIHelper.swift; sourceTree = ""; }; @@ -110,7 +107,6 @@ 2E468AAB1E39B123009C6CA3 /* Aria2Task.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Aria2Task.swift; sourceTree = ""; }; 2E468AAD1E39BA45009C6CA3 /* Aria2Constants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Aria2Constants.swift; sourceTree = ""; }; 2E5DC59B1E69879600184E0B /* ResizableTabViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ResizableTabViewController.swift; sourceTree = ""; }; - 2E644A541E41B24D00C6347C /* ServerProfileTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ServerProfileTests.swift; sourceTree = ""; }; 2E644A601E422B1D00C6347C /* ServerProfileArrayController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ServerProfileArrayController.swift; sourceTree = ""; }; 2E644A621E42CDD700C6347C /* ServerProfileMenuItemViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ServerProfileMenuItemViewController.swift; sourceTree = ""; }; 2E644A661E42DE4200C6347C /* Aria2Stat.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Aria2Stat.swift; sourceTree = ""; }; @@ -247,9 +243,7 @@ isa = PBXGroup; children = ( 2E9E31D51E59BAB200316B9E /* AMMPreferencesTests.swift */, - 2E045E4F1E3CB39B0079EE52 /* Aria2Tests.swift */, 2E468A6E1E398482009C6CA3 /* Info.plist */, - 2E644A541E41B24D00C6347C /* ServerProfileTests.swift */, ); path = AMMTests; sourceTree = ""; @@ -420,8 +414,6 @@ buildActionMask = 2147483647; files = ( 2E9E31D61E59BAB200316B9E /* AMMPreferencesTests.swift in Sources */, - 2E045E501E3CB39B0079EE52 /* Aria2Tests.swift in Sources */, - 2E644A551E41B24D00C6347C /* ServerProfileTests.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; diff --git a/AMM/Info.plist b/AMM/Info.plist index 5ea170f..a5c6ed9 100644 --- a/AMM/Info.plist +++ b/AMM/Info.plist @@ -17,19 +17,7 @@ CFBundlePackageType APPL CFBundleShortVersionString - 0.4.2 - CFBundleVersion - 170619_1 - LSMinimumSystemVersion - $(MACOSX_DEPLOYMENT_TARGET) - LSUIElement - - NSHumanReadableCopyright - Copyright © 2017 sinkerine. All rights reserved. - NSMainNibFile - MainMenu - NSPrincipalClass - NSApplication + 0.4.3 CFBundleURLTypes @@ -45,5 +33,17 @@ + CFBundleVersion + 170822 + LSMinimumSystemVersion + $(MACOSX_DEPLOYMENT_TARGET) + LSUIElement + + NSHumanReadableCopyright + Copyright © 2017 Sinkerine. All rights reserved. + NSMainNibFile + MainMenu + NSPrincipalClass + NSApplication diff --git a/AMMTests/AMMPreferencesTests.swift b/AMMTests/AMMPreferencesTests.swift index 1224d6e..690a22e 100644 --- a/AMMTests/AMMPreferencesTests.swift +++ b/AMMTests/AMMPreferencesTests.swift @@ -26,8 +26,8 @@ class AMMPreferencesTests: XCTestCase { // This is an example of a functional test case. // Use XCTAssert and related functions to verify your tests produce the correct results. let servers: [ServerProfile] = [ - ServerProfile(uuid: NSUUID().uuidString, aria2: Aria2(ptcl: .ws, host: "host1", port: 1111, path: "/jsonrpc")!, remark: "test1", globalStatRefreshInterval: 1, taskStatRefreshInterval: 1, activeTaskTotal: 5, waitingTaskTotal: 5, stoppedTaskTotal: 5, taskStartNotiEnabled: false, taskPauseNotiEnabled: false, taskCompleteNotiEnabled: false)!, - ServerProfile(uuid: NSUUID().uuidString, aria2: Aria2(ptcl: .ws, host: "host2", port: 1111, path: "/jsonrpc")!, remark: "test2", globalStatRefreshInterval: 1, taskStatRefreshInterval: 1, activeTaskTotal: 5, waitingTaskTotal: 5, stoppedTaskTotal: 5, taskStartNotiEnabled: false, taskPauseNotiEnabled: false, taskCompleteNotiEnabled: false)! + ServerProfile(uuid: NSUUID().uuidString, aria2: Aria2(ptcl: .ws, host: "host1", port: 1111, path: "/jsonrpc")!, remark: "test1", globalStatRefreshInterval: 1, taskStatRefreshInterval: 1, activeTaskTotal: 5, waitingTaskTotal: 5, stoppedTaskTotal: 5, taskStartNotiEnabled: false, taskPauseNotiEnabled: false, taskCompleteNotiEnabled: false, isDefaultServer: false)!, + ServerProfile(uuid: NSUUID().uuidString, aria2: Aria2(ptcl: .ws, host: "host2", port: 1111, path: "/jsonrpc")!, remark: "test2", globalStatRefreshInterval: 1, taskStatRefreshInterval: 1, activeTaskTotal: 5, waitingTaskTotal: 5, stoppedTaskTotal: 5, taskStartNotiEnabled: false, taskPauseNotiEnabled: false, taskCompleteNotiEnabled: false, isDefaultServer: false)! ] preferences.reset() assert(preferences.servers.count == 0) diff --git a/AMMTests/Aria2Tests.swift b/AMMTests/Aria2Tests.swift deleted file mode 100644 index 0125c80..0000000 --- a/AMMTests/Aria2Tests.swift +++ /dev/null @@ -1,44 +0,0 @@ -// -// Aria2Test.swift -// AMM -// -// Created by Sinkerine on 28/01/2017. -// Copyright © 2017 sinkerine. All rights reserved. -// - -import XCTest -@testable import AMM - -class Aria2Tests: XCTestCase { -// let aria2 = Aria2(protocol: defaultProtocol, host: "localhost", port: 6800, path: "/jsonrpc", secret: "15cm") - - override func setUp() { - super.setUp() - // Put setup code here. This method is called before the invocation of each test method in the class. - } - - override func tearDown() { - // Put teardown code here. This method is called after the invocation of each test method in the class. - super.tearDown() - } - - func testExample() { - // This is an example of a functional test case. - // Use XCTAssert and related functions to verify your tests produce the correct results. -// aria2?.connect() -// sleep(1) -// aria2?.getGlobalStat(callback: {stat in -// print(stat) -// }) -// sleep(3) -// aria2?.disconnect() - } - - func testPerformanceExample() { - // This is an example of a performance test case. - self.measure { - // Put the code you want to measure the time of here. - } - } - -} diff --git a/AMMTests/ServerProfileTests.swift b/AMMTests/ServerProfileTests.swift deleted file mode 100644 index 7db2c1b..0000000 --- a/AMMTests/ServerProfileTests.swift +++ /dev/null @@ -1,37 +0,0 @@ -// -// ServerProfileTests.swift -// AMM -// -// Created by Sinkerine on 01/02/2017. -// Copyright © 2017 sinkerine. All rights reserved. -// - -import XCTest -@testable import AMM - -class ServerProfileTests: XCTestCase { -// let server = ServerProfile(uuid: NSUUID().uuidString, host: "localhost", port: 6800, path: "jsonrpc", secret: "15cm", remark: "test", globalStatRefreshInterval: 2, taskStatRefreshInterval: 2, activeTaskMaxNum: 5, waitingTaskMaxNum: 4, stoppedTaskMaxNum: 3) - - override func setUp() { - super.setUp() - // Put setup code here. This method is called before the invocation of each test method in the class. - } - - override func tearDown() { - // Put teardown code here. This method is called after the invocation of each test method in the class. - super.tearDown() - } - - func testExample() { - // This is an example of a functional test case. - // Use XCTAssert and related functions to verify your tests produce the correct results. - } - - func testPerformanceExample() { - // This is an example of a performance test case. - self.measure { - // Put the code you want to measure the time of here. - } - } - -}