diff --git a/TopTabBarView/TopTabBarView.xcodeproj/project.pbxproj b/TopTabBarView/TopTabBarView.xcodeproj/project.pbxproj new file mode 100644 index 0000000..bf9d8a1 --- /dev/null +++ b/TopTabBarView/TopTabBarView.xcodeproj/project.pbxproj @@ -0,0 +1,414 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 693F97161B61D79A00683CCB /* TopTabBarView.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 693F970A1B61D79A00683CCB /* TopTabBarView.framework */; }; + 693F971D1B61D79A00683CCB /* TopTabBarViewTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 693F971C1B61D79A00683CCB /* TopTabBarViewTests.swift */; }; + 693F97271B61D7C800683CCB /* TopTabBarView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 693F97261B61D7C800683CCB /* TopTabBarView.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 693F97171B61D79A00683CCB /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 693F97011B61D79A00683CCB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 693F97091B61D79A00683CCB; + remoteInfo = TopTabBarView; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 693F970A1B61D79A00683CCB /* TopTabBarView.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = TopTabBarView.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 693F970E1B61D79A00683CCB /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 693F97151B61D79A00683CCB /* TopTabBarViewTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TopTabBarViewTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 693F971B1B61D79A00683CCB /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 693F971C1B61D79A00683CCB /* TopTabBarViewTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TopTabBarViewTests.swift; sourceTree = ""; }; + 693F97261B61D7C800683CCB /* TopTabBarView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TopTabBarView.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 693F97061B61D79A00683CCB /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 693F97121B61D79A00683CCB /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 693F97161B61D79A00683CCB /* TopTabBarView.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 693F97001B61D79A00683CCB = { + isa = PBXGroup; + children = ( + 693F970C1B61D79A00683CCB /* TopTabBarView */, + 693F97191B61D79A00683CCB /* TopTabBarViewTests */, + 693F970B1B61D79A00683CCB /* Products */, + ); + sourceTree = ""; + }; + 693F970B1B61D79A00683CCB /* Products */ = { + isa = PBXGroup; + children = ( + 693F970A1B61D79A00683CCB /* TopTabBarView.framework */, + 693F97151B61D79A00683CCB /* TopTabBarViewTests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 693F970C1B61D79A00683CCB /* TopTabBarView */ = { + isa = PBXGroup; + children = ( + 693F97261B61D7C800683CCB /* TopTabBarView.swift */, + 693F970D1B61D79A00683CCB /* Supporting Files */, + ); + path = TopTabBarView; + sourceTree = ""; + }; + 693F970D1B61D79A00683CCB /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 693F970E1B61D79A00683CCB /* Info.plist */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; + 693F97191B61D79A00683CCB /* TopTabBarViewTests */ = { + isa = PBXGroup; + children = ( + 693F971C1B61D79A00683CCB /* TopTabBarViewTests.swift */, + 693F971A1B61D79A00683CCB /* Supporting Files */, + ); + path = TopTabBarViewTests; + sourceTree = ""; + }; + 693F971A1B61D79A00683CCB /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 693F971B1B61D79A00683CCB /* Info.plist */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXHeadersBuildPhase section */ + 693F97071B61D79A00683CCB /* Headers */ = { + isa = PBXHeadersBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXHeadersBuildPhase section */ + +/* Begin PBXNativeTarget section */ + 693F97091B61D79A00683CCB /* TopTabBarView */ = { + isa = PBXNativeTarget; + buildConfigurationList = 693F97201B61D79A00683CCB /* Build configuration list for PBXNativeTarget "TopTabBarView" */; + buildPhases = ( + 693F97051B61D79A00683CCB /* Sources */, + 693F97061B61D79A00683CCB /* Frameworks */, + 693F97071B61D79A00683CCB /* Headers */, + 693F97081B61D79A00683CCB /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = TopTabBarView; + productName = TopTabBarView; + productReference = 693F970A1B61D79A00683CCB /* TopTabBarView.framework */; + productType = "com.apple.product-type.framework"; + }; + 693F97141B61D79A00683CCB /* TopTabBarViewTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 693F97231B61D79A00683CCB /* Build configuration list for PBXNativeTarget "TopTabBarViewTests" */; + buildPhases = ( + 693F97111B61D79A00683CCB /* Sources */, + 693F97121B61D79A00683CCB /* Frameworks */, + 693F97131B61D79A00683CCB /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 693F97181B61D79A00683CCB /* PBXTargetDependency */, + ); + name = TopTabBarViewTests; + productName = TopTabBarViewTests; + productReference = 693F97151B61D79A00683CCB /* TopTabBarViewTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 693F97011B61D79A00683CCB /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0640; + ORGANIZATIONNAME = com.daisukeSato; + TargetAttributes = { + 693F97091B61D79A00683CCB = { + CreatedOnToolsVersion = 6.4; + }; + 693F97141B61D79A00683CCB = { + CreatedOnToolsVersion = 6.4; + }; + }; + }; + buildConfigurationList = 693F97041B61D79A00683CCB /* Build configuration list for PBXProject "TopTabBarView" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + ); + mainGroup = 693F97001B61D79A00683CCB; + productRefGroup = 693F970B1B61D79A00683CCB /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 693F97091B61D79A00683CCB /* TopTabBarView */, + 693F97141B61D79A00683CCB /* TopTabBarViewTests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 693F97081B61D79A00683CCB /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 693F97131B61D79A00683CCB /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 693F97051B61D79A00683CCB /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 693F97271B61D7C800683CCB /* TopTabBarView.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 693F97111B61D79A00683CCB /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 693F971D1B61D79A00683CCB /* TopTabBarViewTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 693F97181B61D79A00683CCB /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 693F97091B61D79A00683CCB /* TopTabBarView */; + targetProxy = 693F97171B61D79A00683CCB /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 693F971E1B61D79A00683CCB /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.4; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + TARGETED_DEVICE_FAMILY = "1,2"; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Debug; + }; + 693F971F1B61D79A00683CCB /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + CURRENT_PROJECT_VERSION = 1; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 8.4; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + VERSIONING_SYSTEM = "apple-generic"; + VERSION_INFO_PREFIX = ""; + }; + name = Release; + }; + 693F97211B61D79A00683CCB /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + INFOPLIST_FILE = TopTabBarView/Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Debug; + }; + 693F97221B61D79A00683CCB /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + DEFINES_MODULE = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + DYLIB_INSTALL_NAME_BASE = "@rpath"; + INFOPLIST_FILE = TopTabBarView/Info.plist; + INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SKIP_INSTALL = YES; + }; + name = Release; + }; + 693F97241B61D79A00683CCB /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + FRAMEWORK_SEARCH_PATHS = ( + "$(SDKROOT)/Developer/Library/Frameworks", + "$(inherited)", + ); + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + INFOPLIST_FILE = TopTabBarViewTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Debug; + }; + 693F97251B61D79A00683CCB /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + FRAMEWORK_SEARCH_PATHS = ( + "$(SDKROOT)/Developer/Library/Frameworks", + "$(inherited)", + ); + INFOPLIST_FILE = TopTabBarViewTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 693F97041B61D79A00683CCB /* Build configuration list for PBXProject "TopTabBarView" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 693F971E1B61D79A00683CCB /* Debug */, + 693F971F1B61D79A00683CCB /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 693F97201B61D79A00683CCB /* Build configuration list for PBXNativeTarget "TopTabBarView" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 693F97211B61D79A00683CCB /* Debug */, + 693F97221B61D79A00683CCB /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; + 693F97231B61D79A00683CCB /* Build configuration list for PBXNativeTarget "TopTabBarViewTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 693F97241B61D79A00683CCB /* Debug */, + 693F97251B61D79A00683CCB /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; +/* End XCConfigurationList section */ + }; + rootObject = 693F97011B61D79A00683CCB /* Project object */; +} diff --git a/TopTabBarView/TopTabBarView.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/TopTabBarView/TopTabBarView.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..fcafcb6 --- /dev/null +++ b/TopTabBarView/TopTabBarView.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/TopTabBarView/TopTabBarView.xcodeproj/xcshareddata/xcschemes/TopTabBarView.xcscheme b/TopTabBarView/TopTabBarView.xcodeproj/xcshareddata/xcschemes/TopTabBarView.xcscheme new file mode 100644 index 0000000..6ce3637 --- /dev/null +++ b/TopTabBarView/TopTabBarView.xcodeproj/xcshareddata/xcschemes/TopTabBarView.xcscheme @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/TopTabBarView/TopTabBarView/Info.plist b/TopTabBarView/TopTabBarView/Info.plist new file mode 100644 index 0000000..03cf21b --- /dev/null +++ b/TopTabBarView/TopTabBarView/Info.plist @@ -0,0 +1,26 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + com.daisukeSato.$(PRODUCT_NAME:rfc1034identifier) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + FMWK + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + $(CURRENT_PROJECT_VERSION) + NSPrincipalClass + + + diff --git a/TopTabBarView/TopTabBarView/TopTabBarView.swift b/TopTabBarView/TopTabBarView/TopTabBarView.swift new file mode 100644 index 0000000..d6309b8 --- /dev/null +++ b/TopTabBarView/TopTabBarView/TopTabBarView.swift @@ -0,0 +1,262 @@ +// +// TopTabBarView.swift +// TopTabBarView +// +// Created by SatoDaisuke on 7/21/15. +// Copyright (c) 2015 com.daisukeSato. All rights reserved. +// + +import UIKit + +protocol TopTabBarViewDelegate: class { + + + // Called after the tab changes, be highlight and moves. + func topTabBarViewDidHighlight(topTabBarView: TopTabBarView, index: Int) + +} + +public class TopTabBarView: UIView, UIScrollViewDelegate { + + weak var delegate: TopTabBarViewDelegate? + + // MARK: Private properties + private var scrollView: UIScrollView! + private var underLine: UIView! + private var topTabBarItems: [UIButton]! + private var scrollViewCustomizedContentWidth: CGFloat! + + // MARK: Initializer + required public init(coder aDecoder: NSCoder) { + fatalError("init(coder:) has not been implemented") + } + + public init(frame: CGRect, items: [TopTabBarItem]) { + super.init(frame: frame) + + setupItems(items) + setupScrollView() + addItems() + setupUnderLine() + + highlight(index: 0) + + } + + // MARK: Setup methods + private func setupItems(items: [TopTabBarItem]) { + + self.topTabBarItems = [UIButton]() + self.scrollViewCustomizedContentWidth = 0 + + for idx: Int in 0.. 0 && distanceRight > self.frame.width / 2 { + + newContentOffsetX = button.center.x - (self.frame.width / 2) + + } else if button.center.x - (self.frame.width / 2) <= 0 { + + newContentOffsetX = 0.0 + + } else { + + newContentOffsetX = self.scrollView.contentSize.width - self.frame.width + + } + + + self.scrollView.setContentOffset(CGPointMake( + newContentOffsetX, + 0.0 + ), + animated: true + ) + + + self.delegate?.topTabBarViewDidHighlight(self, index: index) + + } + + private func fixContentWidth() { + + let remainingSpace = self.frame.width - self.scrollViewCustomizedContentWidth + let dividedSpace = remainingSpace / CGFloat(self.topTabBarItems.count) + let newSpace = dividedSpace / 2 + + self.scrollViewCustomizedContentWidth = 0 + + for idx: Int in 0.. + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + com.daisukeSato.$(PRODUCT_NAME:rfc1034identifier) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + + diff --git a/TopTabBarView/TopTabBarViewTests/TopTabBarViewTests.swift b/TopTabBarView/TopTabBarViewTests/TopTabBarViewTests.swift new file mode 100644 index 0000000..b46b262 --- /dev/null +++ b/TopTabBarView/TopTabBarViewTests/TopTabBarViewTests.swift @@ -0,0 +1,36 @@ +// +// TopTabBarViewTests.swift +// TopTabBarViewTests +// +// Created by SatoDaisuke on 7/24/15. +// Copyright (c) 2015 com.daisukeSato. All rights reserved. +// + +import UIKit +import XCTest + +class TopTabBarViewTests: XCTestCase { + + 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. + XCTAssert(true, "Pass") + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measureBlock() { + // Put the code you want to measure the time of here. + } + } + +}