Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Unit Test performs

Former Member
0 Likes
472

Hi guys,

I am watching a strange behaviour while running Unit Tests (Abap Unit).

When i perform the tests SE38 -> Menu: Program -> Test -> Unit Test (Ctrl-Shift-F10)

The database rolls back at the end. Nice.

But: if i write out one line to list (e.g. write: / 'blabla'.) the result is different.

Then i have the database rollback skipped.

Probably due to the list processing, which obligizes a db commit when showing up the list.

do you agree? am i wrong?

Regards,

Hartmut

1 ACCEPTED SOLUTION
Read only

former_member183804
Active Contributor
0 Likes
430

Hello Hartmut,

a unit test must not contain any interactive technique. Especially list commands will cause a popup to appear which will make executing the tests a pain and possibly cause an implict db commit.

The cure to this desease is to avoid list commands.

Regards

Klaus

2 REPLIES 2
Read only

former_member183804
Active Contributor
0 Likes
431

Hello Hartmut,

a unit test must not contain any interactive technique. Especially list commands will cause a popup to appear which will make executing the tests a pain and possibly cause an implict db commit.

The cure to this desease is to avoid list commands.

Regards

Klaus

Read only

0 Likes
430

... there is a single poor "write" statement yet too much list processing causing the db to commit. seems not being mature yet.

Best regards

Hartmut