bisect-kit: clean up code for python2 compability
- python3 added 'mock' to unittest module
- all classes are inherits from "object" in python3
BUG=None
TEST=unittest
Change-Id: I47cc00c006cd2d81ec357a6ad5e514a15bc1f667
diff --git a/bisect_kit/codechange.py b/bisect_kit/codechange.py
index b1b1347..48bc7ba 100644
--- a/bisect_kit/codechange.py
+++ b/bisect_kit/codechange.py
@@ -116,7 +116,7 @@
return repo_url
-class PathSpec(object):
+class PathSpec:
"""Specified code version of one path.
Attributes:
@@ -146,7 +146,7 @@
return not self == rhs
-class Spec(object):
+class Spec:
"""Collection of PathSpec.
Spec is analogy to gclient's DEPS and repo's manifest.
@@ -254,7 +254,7 @@
logger.info('and common=%s', common_count)
-class Action(object):
+class Action:
"""Actions describe changes from one Spec to another.
Attributes:
@@ -291,7 +291,7 @@
return action
-class ActionGroup(object):
+class ActionGroup:
"""Atomic group of Action objects
This models atomic actions, ex:
@@ -473,7 +473,7 @@
batch_apply(commits)
-class SpecManager(object):
+class SpecManager:
"""Spec related abstract operations.
This class enumerates Spec instances and switch disk state to Spec.
@@ -519,7 +519,7 @@
raise NotImplementedError
-class CodeStorage(object):
+class CodeStorage:
"""Query code history and commit relationship without checkout.
Because paths inside source tree may be deleted or map to different remote
@@ -624,7 +624,7 @@
return True
-class CodeManager(object):
+class CodeManager:
"""Class to reconstruct historical source tree state.
This class can reconstruct all moments of source tree state and diffs between