Add possibility to specify a limit for visits in Live.getVisitorProfile #9390
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
fixes #9046
I tried to write some tests for it but failed. Problem: I couldn't really find a fixture where we have many different visits of the same visitor. Tried to write one for a visitor having only a few visits but couldn't figure out the
visitorId
. I could probably get it by logging it in tracking when tests execute them but not trivial when there are also tracking requests for other users etc. It would be doable though. Does anyone maybe know a fixture defining many visits for one visitor? Then I'd add a test for it.Also: I have not named it
filter_limit
orfilter_offset
since this would be not really correct. As mentioned here #9046 (comment) these parameters are reserved for the root element. However,lastVisits
is not a root element. Applyingfilter_limit/filter_offset
forlastVisits
property would be confusing since someone else might expect it to apply forcountries
or another property. Therefore I added a new parameterlimitVisits
. Let me know if there are any other thoughts on this.