Educação | 24.Agosto.2017

Creating custom ViewMatcher for espresso

Por Thiago Lopes Silva

Hello my friends. It’s been a while since I’ve been writing here, right ? let’s go further and learn how to create a custom ViewMatcher for espresso on specific scenarios of testing.
Before going further I recommend you to take a look at this post to learn a few about espresso and this one to learn about the Hamcrest library. It’s used a lot by espresso to match views and do tests that will be our focus on this post.

Let´s start

Sometimes when you are doing e2e tests you need to create custom Matcher that attend your business rules. I will tech you how to solve this particular problem using a great feature named ViewMatcher.

Scenario:

Given customer has tried to logged into his account When the internet is slow Then the button login must change it´s color to red

Leia o restante do post clicando aqui. 
 

Este é um espaço de opinião dos colaboradores do CESAR.
São visões pessoais que não necessariamente refletem o pensamento da organização.

Twitter

OFFICES

RECIFE
HEADQUARTERS | +55 81 3425.4700
Rua Bione, 220 - Cais do Apolo
Bairro do Recife - Recife/PE
ZIP CODE: 50.030-390
GENERAL TAXPAYER’S REGISTRY (CNPJ): 01.203.327/0001-23
Ver no mapa
SOROCABA
BRANCH | +55 15 3316.1400
Av. Itavuvu, 11777 – Salas 07 e 09
PTS – Polo Tecnológico de Sorocaba
Sorocaba/SP
ZIP CODE: 18078 -005
Ver no mapa
CURITIBA
BRANCH | +55 41 3016.5688 // 3022.3415
Rua Padre Anchieta, 2454
Salas 1602 a 1605, Bigorrilho
Curitiba/PR
Zip code: 80730 -000
Ver no mapa
MANAUS
BRANCH | +55 92 3346.2243
Rua Belo Horizonte, 19 - salas 1702 a 1707
Edf. The Place
Adrianópolis
Manaus/AM
ZIP CODE: 69057-060
Ver no mapa