Skip to content

Commit

Permalink
Works with Python 3, change test for coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan Peck committed Jan 4, 2015
1 parent 8f6d74a commit 8fc8128
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,5 @@ target/

# ignore vim swp files
*.swp

*,cover
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
language: python
python:
- '2.7'
- '3.4'
env:
- PYTHONPATH=.
install:
Expand Down
2 changes: 1 addition & 1 deletion leef.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def logEvent(self, event_id, keys):
def _createEventString(self, event_id, keys):
header = self._createHeader(event_id)

values = sorted([(str(k) + "=" + str(v)) for k, v in keys.iteritems()])
values = sorted([(str(k) + "=" + str(v)) for k, v in iter(keys.items())])

payload = '\t'.join(values)

Expand Down
2 changes: 1 addition & 1 deletion test_leef.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def testEventString(self):

expected = header + attributes

test_string = self.l._createEventString("1989", keys)
test_string = self.l.logEvent("1989", keys)
self.assertEqual(test_string, expected)


Expand Down

0 comments on commit 8fc8128

Please sign in to comment.