OLD | NEW |
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 "base/mac/call_with_eh_frame.h" | 5 #include "base/mac/call_with_eh_frame.h" |
6 | 6 |
7 #import <Foundation/Foundation.h> | 7 #import <Foundation/Foundation.h> |
8 | 8 |
9 #include "testing/gtest/include/gtest/gtest.h" | 9 #include "testing/gtest/googletest/include/gtest/gtest.h" |
10 | 10 |
11 namespace base { | 11 namespace base { |
12 namespace mac { | 12 namespace mac { |
13 namespace { | 13 namespace { |
14 | 14 |
15 class CallWithEHFrameTest : public testing::Test { | 15 class CallWithEHFrameTest : public testing::Test { |
16 protected: | 16 protected: |
17 void ThrowException() { | 17 void ThrowException() { |
18 @throw [NSException exceptionWithName:@"TestException" | 18 @throw [NSException exceptionWithName:@"TestException" |
19 reason:@"Testing exceptions" | 19 reason:@"Testing exceptions" |
(...skipping 26 matching lines...) Expand all Loading... |
46 saw_exception = true; | 46 saw_exception = true; |
47 } | 47 } |
48 ASSERT_FALSE(saw_exception); | 48 ASSERT_FALSE(saw_exception); |
49 }; | 49 }; |
50 EXPECT_DEATH(catch_exception_lower(), ""); | 50 EXPECT_DEATH(catch_exception_lower(), ""); |
51 } | 51 } |
52 | 52 |
53 } // namespace | 53 } // namespace |
54 } // namespace mac | 54 } // namespace mac |
55 } // namespace base | 55 } // namespace base |
OLD | NEW |