| OLD | NEW |
| 1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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 import os | 5 import os |
| 6 import sys | 6 import sys |
| 7 | 7 |
| 8 | 8 |
| 9 _THIS_DIR = os.path.dirname(os.path.realpath(__file__)) | 9 _THIS_DIR = os.path.dirname(os.path.realpath(__file__)) |
| 10 | 10 |
| 11 # TODO(katesonia): Figure out why os.getenv('APPLICATION_ID') always return | 11 # TODO(katesonia): Figure out why os.getenv('APPLICATION_ID') always return |
| 12 # True for local unittest. | 12 # True for local unittest. |
| 13 # | 13 # |
| 14 # This hack is due to testing setup and code structure. |
| 15 # |
| 14 # The util_scripts/ are stand-alone local scripts and all those local | 16 # The util_scripts/ are stand-alone local scripts and all those local |
| 15 # scripts and utils under it should be imported starting from util_scripts/. | 17 # scripts and utils under it should be imported starting from util_scripts/. |
| 16 # For all the other modules of predator, imports starts from findit/ root dir. | 18 # For all the other modules of predator, imports starts from findit/ root dir. |
| 17 sys.path.insert(0, _THIS_DIR) | 19 sys.path.insert(0, _THIS_DIR) |
| OLD | NEW |