And "user1"postsacommentwithcontent"Other'sfirstcomment"onthefilenamed"/sharedFileToComment.txt"itshouldreturn"201"
When Logginginusingwebas"user0"
And searchingfor"first"inapp"files"
Then thelistofsearchresultshas"1"results
And searchresult"0"contains
|type |comment |
|comment |Other'sfirstcomment |
|authorId |user1 |
|authorName |user1 |
|path |sharedFileToComment.txt |
|fileName |sharedFileToComment.txt |
|name |Other'sfirstcomment |
Scenario: Search several comments on a file belonging to myself
Given user"user0"exists
And User"user0"uploadsfile"data/textfile.txt"to"/myFileToComment.txt"
And "user0"postsacommentwithcontent"Myfirstcommenttobefound"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Thesecondcommentshouldnotbefound"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Mythirdcommenttobefound"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
When Logginginusingwebas"user0"
And searchingfor"commenttobefound"inapp"files"
Then thelistofsearchresultshas"2"results
And searchresult"0"contains
|type |comment |
|comment |Mythirdcommenttobefound |
|authorId |user0 |
|authorName |user0 |
|path |myFileToComment.txt |
|fileName |myFileToComment.txt |
|name |Mythirdcommenttobefound |
And searchresult"1"contains
|type |comment |
|comment |Myfirstcommenttobefound |
|authorId |user0 |
|authorName |user0 |
|path |myFileToComment.txt |
|fileName |myFileToComment.txt |
|name |Myfirstcommenttobefound |
Scenario: Search comment with a large message ellipsized on the right
Given user"user0"exists
And User"user0"uploadsfile"data/textfile.txt"to"/myFileToComment.txt"
And "user0"postsacommentwithcontent"Averyverbosemessagethatismeanttobeusedtotesttheellipsizedmessagereturnedwhensearchingforlongcomments"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
Scenario: Search comment with a large message ellipsized on the left
Given user"user0"exists
And User"user0"uploadsfile"data/textfile.txt"to"/myFileToComment.txt"
And "user0"postsacommentwithcontent"Averyverbosemessagethatismeanttobeusedtotesttheellipsizedmessagereturnedwhensearchingforlongcomments"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
Scenario: Search comment with a large message ellipsized on both ends
Given user"user0"exists
And User"user0"uploadsfile"data/textfile.txt"to"/myFileToComment.txt"
And "user0"postsacommentwithcontent"Averyverbosemessagethatismeanttobeusedtotesttheellipsizedmessagereturnedwhensearchingforlongcomments"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Myfirstcommenttobefound"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Thesecondcommentshouldnotbefound"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Myfirstcommenttobefound"onthefilenamed"/mySharedFileToComment.txt"itshouldreturn"201"
And "user1"postsacommentwithcontent"Other'sfirstcommentthatshouldnotbefound"onthefilenamed"/mySharedFileToComment.txt"itshouldreturn"201"
And "user1"postsacommentwithcontent"Other'ssecondcommenttobefound"onthefilenamed"/mySharedFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Myfirstcommentthatshouldnotbefound"onthefilenamed"/sharedFileToComment.txt"itshouldreturn"201"
And "user1"postsacommentwithcontent"Other'sfirstcommenttobefound"onthefilenamed"/sharedFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Mysecondcommenttobefoundthathappenstobemoreverbosethantheothersandthusshouldbeellipsized"onthefilenamed"/sharedFileToComment.txt"itshouldreturn"201"
And "user0"postsacommentwithcontent"Mythirdcommenttobefound"onthefilenamed"/myFileToComment.txt"itshouldreturn"201"