Skip to content

Commit f39645b

Browse files
author
Carlos Atencio
committed
Updating README
1 parent 80d67eb commit f39645b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,11 +149,12 @@ Defining `params`, `queryString`, `headers`, or `data` will help the plugin matc
149149

150150
Headers must be defined as the headers that will be used in the http call. Therefore, if in the code to be tested, the headers are defined using properties with function values, these functions will be evaluated as per the $http specification and matched by end result.
151151

152-
Protractor mock will respond with the **last** matched request in case there are several matches.
153-
154152
#### Response
155153
The default `status` value is 200 if none is specified.
156154

155+
### Precendence
156+
protractor-http-mock will respond with the **last** matched request in case there are several matches. The plugin will start matching the default mocks first, followed by those added within the test itself in the order they are added. In other words, the last mock defined will always win.
157+
157158
### Inspection
158159
For testing or debugging purposes, it is possible to extract a list of http requests. Simply call the `requestsMade` function as follows:
159160

0 commit comments

Comments
 (0)