Highlights
Swift Test Training Course:
- Overview of Swift and Xcode IDE
- Swift Constants, Strings and Data Types
- Constant Arrays, Tuples and Constant Dictionary
- Explore Ranges, Intervals, Strides and Slices
- Go through your First Program in Swift
- Learn Functional Collection Processing
- Swift Testing Basics and testing traits
- Explore Program flow and conditions
- More advanced Swift Testing features
- Learn to use variables, loops and structures
Course Details
Overview of Swift and Xcode IDE
- Overview of Swift
- History of Swift and Swift Testing
- Advantages of using Swift Testing
- Walk through of all the main features of the Xcode IDE for testing
- Understand sandboxing
- Code debugging facilities
Your First Program in Swift
- Writing a Swift “Hello World” program
- Structure of a Swift program
- Adding tests to a Swift Program
- Running and debugging Swift Code
Swift Constants, Strings and Data Types
- Constants
- Why are Constants good for debugging
- Strings
- String Literals
- Combining Stings
- String methods
- Multiline String literals
- Extended string delimiters
- Swift built in data types (Bool, Int, String…etc.)
- Type inference
- Specifying a Type
Constant Arrays and Tuples
- Using Constant Arrays
- Creating Arrays
- Array literals
- Retrieving values
- Combining Arrays
- Multidimensional Arrays
- Array methods
- Tuples
- Composing a Tuple
- Decomposing a Tuple
- Name elements of a Tuple
- Access elements of a Tuple by index
- Ignoring Elements
- Understand the different properties
- Understand Spacers
Basic Operators
- Using operators
- Operator examples
Ranges, Intervals, Strides and Slices
- Ranges
- Closed Range
- Half-Open Range
- One-sided Range
- Intervals
- Strides
- through
- to
- Slices
- What is an Array Slice
- How indexes work in an Array Slice
- Array methods that produce slices
Built-in functions and methods
- Various functions and methods supplied by the Swift Language
- abs, contains, joined, dump…etc
Closures (anonymous functions)
- Declaring a Closure
- Type inference when using closures
- Ternary operator
- Variadic Parameters
- Closures as a parameter
- Passing a Closure
- Returning a Closure
- Returning a Tuple
- Trailing brackets
Program flow and conditions
- if
- if / else
- switch
- fallthrough
- guard else
- Expressions
- if / else
- switch
Optionals (handling nil Types)
- nil Type
- if statements and Forced Unwrapping
- optional binding
- if let
- case let and where
- guard let else
- Define optional Types
- Implicitly Unwrapped Optionals
Enumerations
- Defining an Enumerator
- Add member values
- Matching Enumeration Values
- Raw values
- Associated value
- Enumeration Instance Methods
- Initialisers
Constant Dictionaries
- Dictionary properties
- Dictionary literal
- Retrieve an item from a Dictionary
- Extracting Keys and Values
- Embedded Arrays and Dictionaries
Pattern Matching
- Various examples of using the switch statement to pattern match
- Pattern match different types
- Using expressions
Functions
- Functions v Closures
- Defining Functions
- Calling Functions
- Invoking Functions
- Overloading Functions
- Function parameter names
- Default values
- Nested Functions
- Recursion
Functional Collection Processing
- Processing collections with methods sorted
- Map
- Filter
- Reduce
- zip
Using Variables
- Strings
- Arrays
- Dictionaries
- Operators
Loops
- for
- while
- repeat while
- Iterate over collection types
- Strings
- Arrays
- Enumerations
- Dictionaries
- Line names
Structures
- Declaring a Structure
- Create an instance
- Properties
- Copying values
- Instance Methods
- Mutating
- Initialisers
Classes
- Declaring a Class
- Create an Object
- Properties
- Reference types
- Instance Methods
- Identity Operators
- Computed properties
- Initialisers
- De-initialisers
- Inheritance
- Base Classes
- Subclasses
Error Handling
- Using Enumerations for error handling
- @Throws
- Using do-catch
Memory management
- ARC
- References
- Strong
- Weak
- dismantle
Overview of Async/Await
- What is multi-threading
- A multi-threading program
Swift Testing Basics
- Import
- @Test
- @testable
- Validate with #expect
- Adding a display name to a test
- Adding more functions
- Suites
- Stored properties
Swift Testing Traits
- Conditional traits
- Unconditionally disable
- Bug trait
- Conditionalize a test
- When to use @available
- Tags
- Sub-suites
- @Suites and tags inheritance
Parameterized @Test Function
- Consolidate repetitive tests
- Parameterized @Test Function
- For-in loop practices
- Refactoring
Swift Packages
- Overview of Swift packages
- Create a simple package with @Test Functions
- Run a package from a command line.
More advanced Swift Testing features
- Dealing with throwing functions
- Validating the type of error using #expect
- General
- Specific
- Complicated
- throws
- Required
- Using withKnownIssues
- Testing with Ennumerations
- Async/Await
Who should attend
Anyone interested in developing iOS applications should attend a Swift test course. It is ideal for software developers, quality assurance testers, and tech enthusiasts aiming to enhance their Swift programming skills. Beginners wanting to learn the basics and experienced developers seeking to refine their expertise will benefit.
Additionally, project managers looking to understand the testing process in iOS development are encouraged to join.
Feedback
4.8 out of 5 average
"Our tailored course provided a well rounded introduction and also covered some intermediate level topics that we needed to know. Clive gave us some best practice ideas and tips to take away. Fast paced but the instructor never lost any of the delegates"
Brian Leek, Data Analyst, May 2022
“JBI did a great job of customizing their syllabus to suit our business needs and also bringing our team up to speed on the current best practices. Our teams varied widely in terms of experience and the Instructor handled this particularly well - very impressive”
Brian F, Team Lead, RBS, Data Analysis Course, 20 April 2022