Highlights
- Introduction to Kotlin and testing
- Learn Basic Kotlin values, types and literals
- Understand the basics of Kotlin functions, syntax and structure
- Write and execute simple Kotlin programs
- Apply Kotlin to automate testing tasks
- Explore Object expression, object declaration, and companion object
- Gain practical experience through hands-on exercises and real-world examples
Course Details
Introduction
- Overview of Kotlin
- History and features of Kotlin
- Advantages of using Kotlin for testing
- Setting up the Kotlin environment
Your First Program in Kotlin
- Writing a "Hello, World!" program
- Understanding the structure of a Kotlin program
- Running and debugging Kotlin code
Basic Kotlin Values, Types, and Literals
- Variables and constants
- val vs var
- Common data types (Int, String, Boolean, etc.)
- Type inference
- Basic literals (numbers, characters, strings)
Conditional Statements
- If-else statements
- When expression
- Conditional expressions
Functions
- Defining and calling functions
- Syntax and structure
- Function parameters and return types
- Default and named arguments
For-loop
- Iterating over ranges, arrays, and collections
- Using indices and withIndex()
Nullability
- Nullable types
- Declaring nullable variables
- Safe calls and the Elvis operator
- Not-null assertion
Classes
- Defining classes and creating objects
- Constructors and initializer blocks
- Properties and methods
Inheritance
- Basic concepts of inheritance
- Extending classes
- Overriding methods and properties
Data Classes
- Defining and using data classes
- Auto-generated functions (toString, equals, hashCode, copy)
Exceptions
- Exception handling (try-catch-finally)
- Throwing exceptions
- Custom exceptions
Enums
- Defining and using enum classes
- Enum constants and properties
Sealed Classes
- Defining sealed classes
- Using sealed classes for representing restricted class hierarchies
Object Expression, Object Declaration, and Companion Object
- Creating singletons with object expressions and declarations
- Using companion objects for factory methods and static members
Type System
- Understanding Kotlin's type system
- Type casting (safe and unsafe)
- Smart casts
Extension Functions
- Defining and using extension functions
- Extension properties
Functional Programming in Kotlin
- Basics of functional programming
- Higher-order functions and lambdas
Lambda Expressions and Function Types
- Defining and using lambda expressions
- Function types and type aliases
Inline Functions
- Understanding inline functions
- Benefits and use cases
Function References
- Using function references for higher-order functions
- Member and extension references
Functional Collection Processing
- Processing collections with functional methods (map, filter, reduce, etc.)
- Transformations and aggregations
Scope Functions
- Overview of scope functions (let, run, with, apply, also)
- Use cases and best practices
Interoperability Between Kotlin and Java
- Calling Java code from Kotlin
- Calling Kotlin code from Java
- Handling nullability and SAM conversions
Rules of the Idiomatic Kotlin
- Writing clean and idiomatic Kotlin code
- Common conventions and best practices
- Avoiding common pitfalls
Who should attend
- Software Testers: Individuals who want to enhance their testing skills by incorporating Kotlin into their automation frameworks.
- QA Engineers: Quality assurance professionals looking to streamline and improve their automated testing processes using Kotlin.
- Manual Testers: Testers who are transitioning from manual testing to automated testing and wish to learn a versatile and modern programming language.
- Developers: Developers who work closely with testing teams and want to understand how Kotlin can be leveraged for testing purposes.
- Beginner Programmers: Individuals with minimal to no programming experience who are interested in learning Kotlin, particularly for its applications in software testing.
- Technical Managers: Managers overseeing testing teams who want to understand the benefits of Kotlin in testing to make informed decisions about adopting new tools and practices.
- Test Automation Engineers: Automation engineers seeking to diversify their programming skills and add Kotlin to their toolset for more efficient scripting and testing.
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