-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(us-autocompletions): add USAutocompletions
- Loading branch information
Kyle Kwong
committed
May 18, 2018
1 parent
658d679
commit 056af8f
Showing
4 changed files
with
27 additions
and
1 deletion.
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
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
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
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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import unittest | ||
import lob | ||
|
||
|
||
class TestUSAutocompletionFunctions(unittest.TestCase): | ||
def setUp(self): | ||
lob.api_key = 'test_fc26575412e92e22a926bc96c857f375f8b' | ||
|
||
def test_us_autocompletion(self): | ||
autocompletion = lob.USAutocompletion.create( | ||
address_prefix='185 BER', | ||
city='SAN FRANCISCO', | ||
state='CA' | ||
) | ||
|
||
self.assertIn('suggestions', autocompletion) | ||
self.assertEqual(autocompletion.suggestions[0].primary_line, 'TEST KEYS DO NOT AUTOCOMPLETE US ADDRESSES') |