[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
eXept User Forum • View topic - Environment Variable
Ask test developer questions, discuss and share ideas on how to best implement elementary blocks or interfaces.

Environment Variable

Postby AlphaTester » 9. Dec 2008, 09:45

Hello,

I'm using an environment variable. When I start Expecco the variable is set to 1.
During the test this variable is changed.
When I look into the Environment-Tab (after the test) the initalisation value will be displayed(1).
And now I execute this test again: The latest value from the first run will be used (and not 1).

1) is it possible to display the current value of the variable in the environment tab (no test execution)?
2) is it possible to change the value (no test execution)?

Thanks!
--
(while(!asleep())sheep++;)
AlphaTester
 
Posts: 19
Joined: 5. Dec 2008, 08:44
Location: Kerpen

Re: Environment Variable

Postby cgittinger » 11. Dec 2008, 18:10

I agree: we will add some visualization to the next release
(at least an "inspect current value" popUpMenu item - better, an additional column in the variable-editor).

Beside that, I would like to ask for what you think which is the best way to handle variables which are modified by the test. is there a "best practices" pattern which we should recommend ?

One pattern we use often is to have actually two variables, one being readOnly and providing the actual default value, the other being used as a modifyable value during execution. When started, some block is responsible to set the runtime variable to its initial value (*). One variable should be named "initial_X", where X is the name of the runtime variable.

This raises the question, of where such variables should be placed best: obviously, the project-environment is easy to find and central. On the other hand, it is initialized only once: at project load time, or when initialized explictly via the popUpMenu.
A per-test-plan environment or the testcase-actions-environment would probably be better for such mutable runTime values, because they get reinitialized with every execution.

Do you have any other (better) idea for this situation ?

Claus

(*)
actually, it should even be possible to use the "initial_X" in the init-expression of the "X" variable. I.e. in the "X" variable slot, change the "initialization-type" from "Constant" to "Smalltalk Expression", and define the init-expression as "initial_X". However, the current expecco version has a bug in that the project environment is not visible when the init-expressions are evaluated.
This will be fixed in a later version (its obviously so advanced a feature, that most users did not even realize that you can also use a computed expression as initial value of a variable ;-).
cgittinger
 
Posts: 61
Joined: 12. Nov 2008, 17:05

Re: Environment Variable

Postby AlphaTester » 16. Dec 2008, 09:31

--
(while(!asleep())sheep++;)
AlphaTester
 
Posts: 19
Joined: 5. Dec 2008, 08:44
Location: Kerpen


Return to Test Developer Help

Users browsing this forum: No registered users and 1 guest

Design by GB