Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(368)

Issue 12452004: pkg/unittest: locking down TestCase (Closed)

Created:
7 years, 9 months ago by kevmoo-old
Modified:
7 years, 9 months ago
CC:
reviews_dartlang.org
Visibility:
Public.

Description

pkg/unittest: locking down TestCase Strip out most of the public API, leaving only read-only properties that might be interesting for users of unittest. This class is not designed to be instantiated or reused outside of unitttest. The only constructor for TestCase makes strict assumptions about the unittest environment, specifically _currentGroup, _testSetup, _testTeardown. This enables maximum flexibility to evolve and improve the unittest library without concern for supporting random use cases invented by 3rd-parties trying to be clever Before: http://cl.ly/image/41230W032h1d After: http://cl.ly/image/0K0E2S3g1327 All unittest via ./tools/bots/pub.py -n pub-mac pass Committed: https://code.google.com/p/dart/source/detail?r=19972

Patch Set 1 #

Patch Set 2 : fixed up dartdoc on TestCase and updated copyright year #

Total comments: 1

Patch Set 3 : tweak post runtime fix #

Patch Set 4 : ooops with _runningTime setter #

Patch Set 5 : fixed to not break other alternative test configurations #

Total comments: 2

Patch Set 6 : fixed up unneeded getter/setter def, too #

Unified diffs Side-by-side diffs Delta from patch set Stats (+52 lines, -55 lines) Patch
M pkg/unittest/lib/html_layout_config.dart View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M pkg/unittest/lib/interactive_html_config.dart View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M pkg/unittest/lib/src/test_case.dart View 1 2 3 4 5 8 chunks +43 lines, -46 lines 0 comments Download
M pkg/unittest/lib/unittest.dart View 1 2 3 4 6 chunks +7 lines, -7 lines 0 comments Download

Messages

Total messages: 14 (0 generated)
kevmoo-old
7 years, 9 months ago (2013-03-05 15:26:55 UTC) #1
gram
lgtm except for my concern in the comments. We need to make sure that pass/fail/error ...
7 years, 9 months ago (2013-03-05 18:07:41 UTC) #2
gram
On 2013/03/05 18:07:41, gram wrote: > lgtm except for my concern in the comments. We ...
7 years, 9 months ago (2013-03-05 23:25:53 UTC) #3
kevmoo-old
> We do make use of error() in the configs, and fail() in the tests. ...
7 years, 9 months ago (2013-03-05 23:28:25 UTC) #4
gram
On 2013/03/05 23:28:25, kevmoo wrote: > > We do make use of error() in the ...
7 years, 9 months ago (2013-03-05 23:42:04 UTC) #5
kevmoo-old
> fail() is used in unittest_test.dart. This is calling top-level matcher.fail(). No instance of TestCase ...
7 years, 9 months ago (2013-03-05 23:54:41 UTC) #6
kevmoo-old
Scratch deprecated, html_layout_config and interactive_html_config are using eliminated HTML APIs. I don't think they'll work ...
7 years, 9 months ago (2013-03-05 23:57:34 UTC) #7
kevmoo-old
Updated CL to not break layout or interactive Configurations ...still eliminating a lot of unnecessary ...
7 years, 9 months ago (2013-03-13 04:38:18 UTC) #8
gram
lgtm apart from the simple getters/setters. Bob, can you verify that my interpretation of the ...
7 years, 9 months ago (2013-03-13 16:35:58 UTC) #9
kevmoo-old
On 2013/03/13 16:35:58, gram wrote: > lgtm apart from the simple getters/setters. Bob, can you ...
7 years, 9 months ago (2013-03-13 16:45:55 UTC) #10
Siggi Cherem (dart-lang)
https://codereview.chromium.org/12452004/diff/19001/pkg/unittest/lib/src/test_case.dart File pkg/unittest/lib/src/test_case.dart (right): https://codereview.chromium.org/12452004/diff/19001/pkg/unittest/lib/src/test_case.dart#newcode29 pkg/unittest/lib/src/test_case.dart:29: set tearDown(Function value) => _tearDown = value; On 2013/03/13 ...
7 years, 9 months ago (2013-03-13 16:46:04 UTC) #11
kevmoo-old
Added fix for redundant getter/setter in TestCase PTAL
7 years, 9 months ago (2013-03-13 19:10:04 UTC) #12
gram
lgtm
7 years, 9 months ago (2013-03-13 21:06:43 UTC) #13
kevmoo-old
7 years, 9 months ago (2013-03-13 21:19:13 UTC) #14
Message was sent while issue was closed.
Committed patchset #6 manually as r19972 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698