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

Side by Side Diff: Source/core/dom/AttrTest.cpp

Issue 1171323003: Fix unit test style in core/{dom,editing,html}/. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: whitespace fix Created 5 years, 6 months 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
« no previous file with comments | « Source/core/dom/ActiveDOMObjectTest.cpp ('k') | Source/core/dom/DOMImplementationTest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/dom/Attr.h" 6 #include "core/dom/Attr.h"
7 7
8 #include "core/dom/Document.h" 8 #include "core/dom/Document.h"
9 #include <gmock/gmock.h> 9 #include <gmock/gmock.h>
10 #include <gtest/gtest.h> 10 #include <gtest/gtest.h>
11 11
12 using namespace blink; 12 namespace blink {
13
14 namespace {
15 13
16 class AttrTest : public ::testing::Test { 14 class AttrTest : public ::testing::Test {
17 protected: 15 protected:
18 virtual void SetUp() override; 16 void SetUp() override;
19 17
20 PassRefPtrWillBeRawPtr<Attr> createAttribute(); 18 PassRefPtrWillBeRawPtr<Attr> createAttribute();
21 const AtomicString& value() const { return m_value; } 19 const AtomicString& value() const { return m_value; }
22 20
23 private: 21 private:
24 RefPtrWillBePersistent<Document> m_document; 22 RefPtrWillBePersistent<Document> m_document;
25 AtomicString m_value; 23 AtomicString m_value;
26 }; 24 };
27 25
28 void AttrTest::SetUp() 26 void AttrTest::SetUp()
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 } 73 }
76 74
77 TEST_F(AttrTest, LengthOfContents) 75 TEST_F(AttrTest, LengthOfContents)
78 { 76 {
79 RefPtrWillBeRawPtr<Attr> attr = createAttribute(); 77 RefPtrWillBeRawPtr<Attr> attr = createAttribute();
80 EXPECT_EQ(0u, attr->lengthOfContents()); 78 EXPECT_EQ(0u, attr->lengthOfContents());
81 attr->setValue(value()); 79 attr->setValue(value());
82 EXPECT_EQ(0u, attr->lengthOfContents()); 80 EXPECT_EQ(0u, attr->lengthOfContents());
83 } 81 }
84 82
85 } // unnamed namespace 83 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/dom/ActiveDOMObjectTest.cpp ('k') | Source/core/dom/DOMImplementationTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698