Chromium Code Reviews| Index: appengine/findit/crash/test/crash_util_test.py |
| diff --git a/appengine/findit/crash/test/crash_util_test.py b/appengine/findit/crash/test/crash_util_test.py |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..4c17191b0f4dd8877996fa81734258bbbe558223 |
| --- /dev/null |
| +++ b/appengine/findit/crash/test/crash_util_test.py |
| @@ -0,0 +1,26 @@ |
| +# Copyright 2016 The Chromium Authors. All rights reserved. |
| +# Use of this source code is governed by a BSD-style license that can be |
| +# found in the LICENSE file. |
| + |
| +from testing_utils import testing |
| + |
| +from crash import crash_util |
| + |
| + |
| +class CrashUtilTest(testing.AppengineTestCase): |
| + |
| + def testIsSameFilePath(self): |
| + path1 = 'third_party/a/b/c/file.cc' |
| + path2 = 'third_party/a/file.cc' |
| + |
| + self.assertTrue(crash_util.IsSameFilePath(path1, path2)) |
|
stgao
2016/04/15 18:35:19
Why these two are treated as the same file paths?
Sharu
2016/04/15 22:59:47
This is the method we use in clusterfuzz all the t
|
| + |
| + path1 = 'a/b/c/file.cc' |
| + path2 = 'a/b/c/file2.cc' |
| + |
| + self.assertFalse(crash_util.IsSameFilePath(path1, path2)) |
| + |
| + path1 = 'a/b/c/d/e/file.cc' |
| + path2 = 'f/g/file.cc' |
| + |
| + self.assertFalse(crash_util.IsSameFilePath(path1, path2)) |