This repository contains sample project created in testing purposes. It is a simple iOS application that allows user to create todo items and mark them as completed. It uses SwiftUI framework and MVVM architecture.
- IDE: Xcode 13+, Visual Studio Code 1.61+, AppCode 2021.2+
- iOS: iOS 16.4+
This project does not use any third party libraries, this is pure Swift code, that uses only Swift standard library and Swift UI framework.
Clone this repository to your local machine and open TodoApp.xcodeproj
file or containing folder in your favorite IDE.
Visual Studio Code notice: you will not be able to run unit tests from IDE, because it does not support running tests for iOS projects. You can run tests from command line using xcodebuild test
command.
Run xcodebuild
command from project root directory. This command will build project and run all unit tests.
Here is a command example:
xcodebuild -project TodoApp.xcodeproj -scheme TodoApp -destination 'platform=iOS Simulator,name=iPhone 13,OS=16.4' build
If you want to get ipa
file you would need to specify signing identity and provisioning profile:
xcodebuild -project TodoApp.xcodeproj -scheme TodoApp -destination 'platform=iOS Simulator,name=iPhone 13,OS=16.4' -configuration Release CODE_SIGN_IDENTITY="iPhone Developer" PROVISIONING_PROFILE="your provisioning profile" DEVELOPMENT_TEAM="your development team id if needed" archive -archivePath build/TodoApp.xcarchive
Also you may need to specify DEVELOPMENT_TEAM if you have multiple teams in your account. And update Xcode project settings to use automatic signing.
Run xcodebuild test
command from project root directory. This command will build project and run all unit tests.
For example:
xcodebuild -project TodoApp.xcodeproj -scheme TodoApp -destination 'platform=iOS Simulator,name=iPhone 13,OS=16.4' test
Your will get results in console. See here for more details
Apache License 2.0