Skip to content

Commit

Permalink
Merge 304714c into e161347
Browse files Browse the repository at this point in the history
  • Loading branch information
mkelley committed Sep 14, 2018
2 parents e161347 + 304714c commit 5e57725
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sbpy/bib/core.py
Expand Up @@ -29,7 +29,8 @@ def register(task, citations):
"""
global _bibliography, _track
if _track:
_bibliography[task] = citations
_bibliography[task] = _bibliography.get(task, {})
_bibliography[task].update(citations)


def reset():
Expand Down
11 changes: 11 additions & 0 deletions sbpy/bib/tests/test_bib.py
Expand Up @@ -44,3 +44,14 @@ def test_Tracking():
register('test', {'do not track this': 'bibcode'})

assert ['test:', 'track_this:', 'bibcode'] == to_text().split()


def test_Tracking_issue_64():
from sbpy.activity import photo_lengthscale
reset()
with Tracking():
gamma_H2O = photo_lengthscale('H2O')
gamma_OH = photo_lengthscale('OH')
words = to_text().split()
assert 'OH' in words
assert 'H2O' in words

0 comments on commit 5e57725

Please sign in to comment.