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

Side by Side Diff: chrome/test/data/unit/framework_unittest.gtestjs

Issue 8438063: Make it possible to include another file and port print_preview unit test to unit_tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 /**
6 * Class for testing the unit_test framework.
7 * @constructor
8 */
9 function FrameworkUnitTest() {}
10
11 FrameworkUnitTest.prototype = {
12 __proto__: testing.Test.prototype,
13 };
14
15 TEST_F('FrameworkUnitTest', 'testExpectTrueOk', function() {
16 expectTrue(true);
17 });
18
19 TEST_F('FrameworkUnitTest', 'testAssertTrueOk', function() {
20 assertTrue(true);
21 });
22
23 /**
24 * Failing version of FrameworkUnitTest.
25 * @constructor
26 */
27 function FrameworkUnitTestFail() {}
dpapad 2011/11/03 16:14:34 I think that this could be compressed a bit as fol
arv (Not doing code reviews) 2011/11/03 19:04:12 That is bad practice. The following would fail the
Sheridan Rawlins 2011/11/05 16:51:25 Ok, so this is a nop. <not> Done. :) On 2011/11
28
29 FrameworkUnitTestFail.prototype = {
30 __proto__: FrameworkUnitTest.prototype,
31
32 /** inheritDoc */
33 testShouldFail: true,
34 };
35
36 TEST_F('FrameworkUnitTestFail', 'testExpectFailFails', function() {
37 expectNotReached();
38 });
39
40 TEST_F('FrameworkUnitTestFail', 'testAssertFailFails', function() {
41 assertNotReached();
42 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698