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

Side by Side Diff: recipe_engine/simulation_test.py

Issue 2702313003: Remove unused imports and fix some other linter errors. (Closed)
Patch Set: Created 3 years, 10 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
OLDNEW
1 # Copyright 2014 The LUCI Authors. All rights reserved. 1 # Copyright 2014 The LUCI Authors. All rights reserved.
2 # Use of this source code is governed under the Apache License, Version 2.0 2 # Use of this source code is governed under the Apache License, Version 2.0
3 # that can be found in the LICENSE file. 3 # that can be found in the LICENSE file.
4 4
5 """Provides simulator test coverage for individual recipes.""" 5 """Provides simulator test coverage for individual recipes."""
6 6
7 import StringIO 7 import StringIO
8 import ast
9 import contextlib
10 import copy 8 import copy
11 import json 9 import json
12 import logging 10 import logging
13 import os 11 import os
14 import re 12 import re
15 import sys 13 import sys
16 import textwrap
17 import traceback
18 import inspect
19 14
20 from collections import OrderedDict, namedtuple 15 from . import env
21 16
22 from . import config_types 17 from . import config_types
23 from . import env
24 from . import loader 18 from . import loader
25 from . import run 19 from . import run
26 from . import step_runner 20 from . import step_runner
27 from . import stream 21 from . import stream
28 from expect_tests.util import covers as expect_tests_covers
Vadim Sh. 2017/02/21 05:46:26 I hope it isn't some magical import that enables s
iannucci 2017/02/21 06:07:47 Shouldn't be...
29 from expect_tests.main import main as expect_tests_main 22 from expect_tests.main import main as expect_tests_main
30 from expect_tests.type_definitions import Result, Test, FuncCall 23 from expect_tests.type_definitions import Result, Test, FuncCall
31 from .checker import Checker, VerifySubset 24 from .checker import Checker, VerifySubset
32 from google.protobuf import json_format as jsonpb 25 from google.protobuf import json_format as jsonpb
33 26
34 # These variables must be set in the dynamic scope of the functions in this 27 # These variables must be set in the dynamic scope of the functions in this
35 # file. We do this instead of passing because the threading system of expect 28 # file. We do this instead of passing because the threading system of expect
36 # tests doesn't know how to serialize it. 29 # tests doesn't know how to serialize it.
37 _UNIVERSE_VIEW = None 30 _UNIVERSE_VIEW = None
38 _ENGINE_FLAGS = None 31 _ENGINE_FLAGS = None
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 logging.warn("Ignoring %s environment variable." % env_var) 233 logging.warn("Ignoring %s environment variable." % env_var)
241 os.environ.pop(env_var) 234 os.environ.pop(env_var)
242 235
243 global _UNIVERSE_VIEW 236 global _UNIVERSE_VIEW
244 _UNIVERSE_VIEW = universe_view 237 _UNIVERSE_VIEW = universe_view
245 global _ENGINE_FLAGS 238 global _ENGINE_FLAGS
246 _ENGINE_FLAGS = engine_flags 239 _ENGINE_FLAGS = engine_flags
247 240
248 expect_tests_main('recipe_simulation_test', GenerateTests, 241 expect_tests_main('recipe_simulation_test', GenerateTests,
249 cover_omit=cover_omit(), args=args) 242 cover_omit=cover_omit(), args=args)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698