-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
These tests are responsible for validating that a single unit is working properly. You can think of a unit as a class or function. These tests are written in an isolated fashion. I mean, if the rest of the system is full of bugs and nothing else work, if this unit work, the test will pass. They are also repeatable. They don't depend on anything else, really. Anytime you run the test, if the code hasn't changed, the test will report the same result. These tests are intimately related to the code quality of your project. If your code is clean, these tests should be relatively easy to write. When writing unit tests in iOS, you usually use XCTest or Quick
Well, enough theory for now. I've prepared a quick, small example so you can understand hands-on how all of this work. So, go and clone/download the code in this repo. This is the simplest app you could think of. It's a Counter app, that has a label in the center of the screen, a button to "add" and a button to "sub". As simple as that. A think that could draw your attention is this fragment:
Now, download Appium Desktop from this link.
If you were able to follow up until now, well done! You've just run Appium for the first time, and inspected your app in the Appium Inspector. Now, stop the Appium Desktop server, and let's start with the actual tests. Before going on, you'll need to install nodejs, preferably by using nvm, although that's out of the scope for this tutorial. Once you've that installed, let's create a new folder and open the terminal inside it. We need to start a new Nodejs app, so I'll run npm init -y to accept the default arguments.
So this is new for me. I normally write posts explaining things I've been doing in a daily basis for many years. However, I started working for a new client somethings like a month ago. I'll talk about the team organization at some point, in another post, because I really like how these guys work. However, this post is about end-to-end tests. In the team I'm now taking part of, everyone is responsible for writing e2e tests for iOS/Android/Web. I've never done that before, I have to confess. I've done Unit tests many many times, but I've never written so many integration tests. Appium, WebdriverIO and Jasmine are the tools this team has chosen to write these tests, and for good reasons. Let's first distinguish briefly among the different types of automated tests. Particularly between e2e and unit tests.
Related posts
-
Write a schema only absolutely no code backend server with Node.js and Teo!
-
How to quickly setup NodeJS with NVM
-
"npm can’t be eliminated from the equation when you’re dealing with JavaScript" - True or false?
-
Supercharge your Windows Development: The Ultimate Guide to WSL 🚀📟
-
Two+ things I do every time I set up a new node project