-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
skip ex 10 test if BSON not installed
- Loading branch information
Showing
1 changed file
with
4 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,7 @@ | ||
import json | ||
import unittest | ||
|
||
import time | ||
|
||
from bson import json_util | ||
|
||
from chronograph.chronograph import Chronograph, get_split_time, get_chronograph, ChronographError, add_chronograph | ||
|
||
__author__ = 'Anubhav Jain <[email protected]>' | ||
|
@@ -135,6 +132,10 @@ def func2(): | |
self.assertAlmostEqual(cg2.total_elapsed_time, 0.25, 1) | ||
|
||
def test_example10(self): | ||
try: | ||
from bson import json_util | ||
except: | ||
raise unittest.SkipTest("bson package not installed") | ||
cg = Chronograph(start_timing=True) | ||
time.sleep(0.25) | ||
cg.split("s2") | ||
|