Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Jubula » Use of check text and not equal to operator(Rookie question on what I am doing wrong)
Use of check text and not equal to operator [message #1125568] Fri, 04 October 2013 16:56 Go to next message
Todd P is currently offline Todd PFriend
Messages: 10
Registered: October 2012
Junior Member
Thanks for some quick help. I am sure this is an easy question, but I am struggling to get this work. It might be that my regular expression was not correct.

I have a text field that I want to check. I want to test that the word "checked" is NOT in a string. I have tried various combinations of using the operator "not equals" with wild cards *checked*. I also tried using a matches with regular expressions.

So my example text that I am checking is something like.

file name, checked out (or checked out to)

Re: Use of check text and not equal to operator [message #1127960 is a reply to message #1125568] Mon, 07 October 2013 07:24 Go to previous messageGo to next message
Alexandra Schladebeck is currently offline Alexandra SchladebeckFriend
Messages: 1613
Registered: July 2009
Senior Member
Hi,

There are some examples of using regular expressions in the reference manual. I believe there's an example of how to check for non-existence there.

Hope that helps,
Alex
Re: Use of check text and not equal to operator [message #1128461 is a reply to message #1125568] Mon, 07 October 2013 18:19 Go to previous message
Danila Pod is currently offline Danila PodFriend
Messages: 19
Registered: January 2013
Junior Member
Example of using regular expressions in the reference manual:
^.*[^(EXAMPLE)].*\$
It isn't working and it shouldn't work. Because it will always return true.
From wikipedia:

"[^ ] Matches a single character that is not contained within the brackets. For example, [^abc] matches any character other than "a", "b", or "c". [^a-z] matches any single character that is not a lowercase letter from "a" to "z". Likewise, literal characters and ranges can be mixed."

So in example it matches 'EXAMPLE STRINGEXAMPLE'. The only way to return false is to check the same string 'EXAMPLE'. You can test in any RegExp calc.

As i understood, the only way to "test that the word "checked" is NOT in a string" it's using '.*(?!EXAMPLE).*'

But we have another problem - still non-fixed issue:
http://www.eclipse.org/forums/index.php/t/332273/

Yes, in jubula 7.1 you sill cannot use question mark without single quotes. With single quotes it becomes just a text, not a regExp modificator.

PS offtopic: I used "another problem". Would "another issue" be more correctly in such phrase?..
Previous Topic:Using stored values as Test Data of other TCs
Next Topic:Jubula takes longer to save the changes
Goto Forum:
  


Current Time: Fri Mar 29 08:34:26 GMT 2024

Powered by FUDForum. Page generated in 0.02611 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top