Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork939
Commitb780a8c
committed
Tweak
The situation with test_tree_modifier_ordering's helper, where itmakes sense to wrap the helper itself with `@with_rw_directory`while still deleting the temporary directory as soon as the helperitself finishes, in order to make clear that the test itself doesnot use the temporary directory that the helper used, only occursin one place in GitPython's tests as far as I know.In particular, all other places where `@with_rw_directory` wasactually in use are test methods, not helper methods, and the waythe decorator would have its wrapper log on failure documented thedecorated method as a test. Mainly for that reason, I had backedaway from using `@with_rw_directory` here.But the test code seems much easier to understand when it is usedcompared to other approaches. While it also has the disadvantage ofdoing a gc.collect that is unnecessary here, this is not the onlyplace what that is done.This commit brings back the test_tree_modifier_ordering helperimplementation that uses `@with_rw_directory`, while also modifyingthe logging logic in `@with_rw_directory` slightly, so that whenthe decorated method is not named as a test, it is referred to as a"Helper" rather than a "Test" in the failure log message.@with_rw_directory
and go back to using it1 parent0114a99 commitb780a8c
2 files changed
+32
-36
lines changedLines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
97 | 97 |
| |
98 | 98 |
| |
99 | 99 |
| |
100 |
| - | |
| 100 | + | |
| 101 | + | |
101 | 102 |
| |
102 | 103 |
| |
103 | 104 |
| |
|
Lines changed: 30 additions & 35 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
10 |
| - | |
11 | 10 |
| |
12 | 11 |
| |
13 |
| - | |
14 |
| - | |
| 12 | + | |
| 13 | + | |
15 | 14 |
| |
16 | 15 |
| |
17 | 16 |
| |
| |||
43 | 42 |
| |
44 | 43 |
| |
45 | 44 |
| |
46 |
| - | |
47 |
| - | |
| 45 | + | |
| 46 | + | |
48 | 47 |
| |
49 |
| - | |
50 |
| - | |
51 |
| - | |
52 |
| - | |
53 |
| - | |
54 |
| - | |
55 |
| - | |
56 |
| - | |
57 |
| - | |
58 |
| - | |
59 |
| - | |
60 |
| - | |
61 |
| - | |
62 |
| - | |
63 |
| - | |
64 |
| - | |
65 |
| - | |
66 |
| - | |
67 |
| - | |
68 |
| - | |
69 |
| - | |
70 |
| - | |
71 |
| - | |
72 |
| - | |
73 |
| - | |
74 |
| - | |
75 |
| - | |
76 |
| - | |
77 |
| - | |
78 |
| - | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
79 | 74 |
| |
80 | 75 |
| |
81 | 76 |
| |
|
0 commit comments
Comments
(0)