1---------------------------
2testresources release notes
3---------------------------
4
5IN DEVELOPMENT
6--------------
7
82.0.0
9~~~~~
10
11CHANGES
12~~~~~~~
13
14* Drop support for Python 2.4, 2.5, 3.2: while not deliberately breaking
15  compatibility, we cannot easily test those in CI, so stating that they
16  are supported is at best misleading. (Robert Collins)
17
18IMPROVEMENTS
19~~~~~~~~~~~~
20
211.0.0
22~~~~~
23
24* Unitest2 test suites are properly absorbed and optimised now.
25  (Robert Collins)
26
270.2.7
28-----
29
30IMPROVEMENTS
31~~~~~~~~~~~~
32
33* FixtureResource was not triggering cleanups or resets between uses, this is
34  fixed (but doing so cleanly involved a new extension point - ``_reset`` on
35  ``TestResourceManager``. This is called from ``reset`` which should no
36  longer be overridden. (Though overridden versions will still behave correctly
37  - the change is backwards compatible). Lastly two new TestResult methods were
38  added to track reset (as opposed to make and clean).
39  (Robert Collins, James Westby, #1023423)
40
41* TestResourceManager.reset() was not taking dependency dirtiness into
42  consideration. (Brian Sutherland, #783488)
43
440.2.6
45-----
46
47IMPROVEMENTS
48~~~~~~~~~~~~
49
50* NEWS made clearer. (Martin Pool)
51
52* Python3.2+ compatible. (Robert Collins)
53
540.2.5
55-----
56
57IMPROVEMENTS
58~~~~~~~~~~~~
59
60* Added ``testresources.FixtureResource`` to wrap ``fixtures.Fixture``
61  instances. (Robert Collins)
62
63* super() is now called from ResourcedTestCase fixing a long standing issue
64  with using it as a mix-in in Python 2.4 and above. (Tim Cole, #771505)
65
66* Typo in NEWS fixed. (Thommi Richards)
67
680.2.4
69-----
70
71CHANGES
72~~~~~~~
73
74* Relicenced to BSD / Apache2.0 with full agreement of contributors.
75
76IMPROVEMENTS
77~~~~~~~~~~~~
78
79* Substantially improved documentation in README. (mbp)
80
81* Rename TestResource to TestResourceManager leaving TestResource as an alias.
82  Fixes bug #520769.
83
84* Test sorting no longer performs N! work on tests that can never benefit from
85  order optimisations (when resources are not shared an arbitrary order is
86  sufficient). Partial fix for bug #522338.
87
88* Test sorting now uses a heuristic on each partition to get a sort that is
89  no worse than twice the optimal number of setup/teardown operations and is
90  fast to calculate. Fixes bug #522338
91
920.2.3
93-----
94
95CHANGES
96~~~~~~~
97
98IMPROVEMENTS
99~~~~~~~~~~~~
100
101* Distribute doc/*.py in the source tarball.
102
103* New helper testresources.GenericResource which should remove the need for
104  much boilerplate when using testresources with existing test fixtures.
105
106BUG FIXES
107~~~~~~~~~
108
109API CHANGES
110~~~~~~~~~~~
111
112* New public functions testresources.setUpResources and
113  testresources.tearDownResources for folk that cannot easily use
114  ResourcedTestCase. Fixes bug #504146.
115
116INTERNALS
117~~~~~~~~~
118
1190.2.2
120-----
121
122BUG FIXES
123~~~~~~~~~
124
125* OptimisingTestSuite.addTest was not unpacking OptimisingTestSuite instances.
126  When using testresources.TestLoader to load tests this was generating an
127  unoptimised layout, with each test in its own little suite, and no resource
128  sharing happening.
129
1300.2.1
131------
132
133A small bugfix release for compatibility with newer testtools.
134
135INTERNALS
136~~~~~~~~~
137
138* One test case wasn't upcalling setUp properly, causing test failures with
139  more recent testtools that check for this mistake.
140
1410.2
142---
143
144  CHANGES:
145
146    * testresources needs testtools to run the testresources test suite. You
147      can still use testresources without using testtools. (Jonathan Lange)
148
149  IMPROVEMENTS:
150
151    * Many more docstrings. (Jonathan Lange)
152
153    * Expanded README. (Jonathan Lange)
154
155    * Expanded TODO. (Jonathan Lange)
156
157    * Resources can now be reset by overriding TestResource.reset, which for
158      some resources is significantly cheaper. If checking for dirtiness is
159      expensive, isDirty can also be overridden.
160      (James Henstridge, Robert Collins)
161
162    * Started keeping a NEWS file! (Jonathan Lange)
163
164    * Resource creation and destruction are traced by calling methods on the
165      TestResult object that tests are being run with.
166      (Robert Collins, #284125)
167
168  BUG FIXES:
169
170    * Calling getResource on a dirty resource now triggers a clean and re-make
171      of that resource. (Jonathan Lange)
172
173    * All resources are dropped when a test with no declared resources is run.
174      (James Henstridge)
175
176    * A dirty or changed dependency of a resource makes the resource dirty too.
177      (Robert Collins, #324202)
178
179  API CHANGES:
180
181    * adsorbSuite is now deprecated in favour of addTest. addTest now flattens
182      standard library TestSuites and distributes custom TestSuite across
183      their member tests. (Jonathan Lange)
184
185    * ResourcedTestCase.setUpResources and tearDownResources are now instance
186      methods, not static methods. (Jonathan Lange)
187
188    * All methods on TestResource are now instance methods, and thus tests
189      should use instances of TestResource subclasses, not the classes
190      themselves. (Jonathan Lange)
191
192    * Now imports from testtools rather than pyunit3k. (Jonathan Lange)
193
194    * ResourcedTestCase will now look for resources in the 'resources'
195      attribute, rather than the '_resources' attribute. (Jonathan Lange)
196
197    * ResourcedTestCase.setUpResources and tearDownResources are now instance
198      methods, not static methods. (Jonathan Lange)
199
200    * SampleTestResource has been removed. (Jonathan Lange)
201
202    * TestResource.make has had an API change: it must now accept a
203      dependency_resources parameter which is a dictionary listing the
204      dependencies that will be provided to the resource. This parameter is
205      provided so the resource can access its dependencies during setUp, if
206      needed. (Robert Collins)
207
208    * TestResource subclasses should override 'make' and 'clean' where they
209      previously overrode '_makeResource' and '_cleanResource'.
210      (Jonathan Lange)
211
212    * TestResource.setResource has been renamed to _setResource.
213      (Jonathan Lange)
214
215  INTERNALS:
216
217    * A lot of the tests have been split up into smaller tests. Others have
218      been refactored. (Jonathan Lange)
219
220    * If calling finishedWith on a TestResource reduces its usage count to
221      zero, then the TestResource considers itself clean, i.e. _dirty is set
222      to True. (Jonathan Lange)
223
224    * OptimisingTestSuite has been refactored internally so that the way we
225      switch active resources and determine the cost of switching is more
226      obvious. (Jonathan Lange)
227