-
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.
Removed MySql dep. Added ability to specify custom registry
- Loading branch information
1 parent
d48c652
commit cd31310
Showing
30 changed files
with
57 additions
and
462 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
This file was deleted.
Oops, something went wrong.
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
2 changes: 1 addition & 1 deletion
2
examples/java-spring/src/main/resources/application-touchstone.properties
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
File renamed without changes.
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,4 +1,4 @@ | ||
MYSQL_DATABASE = 'myapp' | ||
MYSQL_TABLE = 'users' | ||
POSTGRES_DATABASE = 'myapp' | ||
POSTGRES_TABLE = 'users' | ||
MONGO_DATABASE = 'myapp' | ||
MONGO_COLLECTION = 'orders' |
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 |
---|---|---|
|
@@ -18,7 +18,7 @@ def given(self) -> object: | |
'lastName': 'Brown', | ||
'email': '[email protected]' | ||
} | ||
self.deps.mysql.setup().insert_row(creds.MYSQL_DATABASE, creds.MYSQL_TABLE, given) | ||
self.deps.postgres.setup().insert_row(creds.POSTGRES_DATABASE, creds.POSTGRES_TABLE, given) | ||
return given | ||
|
||
def when(self, given) -> object: | ||
|
@@ -60,8 +60,8 @@ def then(self, given, result) -> bool: | |
'lastName': given['lastName'], | ||
'email': given['email'] | ||
} | ||
return validation.matches(expected_response, result) and self.deps.mysql.verify().row_exists( | ||
creds.MYSQL_DATABASE, creds.MYSQL_TABLE, given) | ||
return validation.matches(expected_response, result) and self.deps.postgres.verify().row_exists( | ||
creds.POSTGRES_DATABASE, creds.POSTGRES_TABLE, given) | ||
|
||
|
||
class PutUser(TouchstoneTest): | ||
|
@@ -85,15 +85,15 @@ def given(self) -> object: | |
'lastName': 'Brown', | ||
'email': '[email protected]' | ||
} | ||
self.deps.mysql.setup().insert_row(creds.MYSQL_DATABASE, creds.MYSQL_TABLE, existing_user) | ||
self.deps.postgres.setup().insert_row(creds.POSTGRES_DATABASE, creds.POSTGRES_TABLE, existing_user) | ||
return new_info | ||
|
||
def when(self, given) -> object: | ||
http.put_json(f'{self.service_url}/user', given) | ||
return None | ||
|
||
def then(self, given, result) -> bool: | ||
return self.deps.mysql.verify().row_exists(creds.MYSQL_DATABASE, creds.MYSQL_TABLE, given) | ||
return self.deps.postgres.verify().row_exists(creds.POSTGRES_DATABASE, creds.POSTGRES_TABLE, given) | ||
|
||
|
||
class DeleteUser(TouchstoneTest): | ||
|
@@ -117,7 +117,7 @@ def given(self) -> object: | |
'lastName': 'Brown', | ||
'email': '[email protected]' | ||
} | ||
self.deps.mysql.setup().insert_row(creds.MYSQL_DATABASE, creds.MYSQL_TABLE, user) | ||
self.deps.postgres.setup().insert_row(creds.POSTGRES_DATABASE, creds.POSTGRES_TABLE, user) | ||
return user_id | ||
|
||
def when(self, given) -> object: | ||
|
@@ -129,4 +129,4 @@ def then(self, given, result) -> bool: | |
'id': given | ||
} | ||
return self.deps.rabbitmq.verify().payload_published('user.exchange', str(given), 'user-deleted') and \ | ||
self.deps.mysql.verify().row_does_not_exist(creds.MYSQL_DATABASE, creds.MYSQL_TABLE, where) | ||
self.deps.postgres.verify().row_does_not_exist(creds.POSTGRES_DATABASE, creds.POSTGRES_TABLE, where) |
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 |
---|---|---|
|
@@ -9,4 +9,4 @@ dependencies: | |
rabbitmq: | ||
auto_create: False | ||
mongodb: | ||
mysql: | ||
postgres: |
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
Binary file not shown.
File renamed without changes.
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 |
---|---|---|
|
@@ -19,7 +19,7 @@ def given(self) -> object: | |
writer.writerow(['name', 'email']) | ||
writer.writerow(['John', '[email protected]']) | ||
writer.writerow(['Jane', '[email protected]']) | ||
self.deps.mysql.setup().insert_rows('myapp', 'numbers', [ | ||
self.deps.postgres.setup().insert_rows('myapp', 'numbers', [ | ||
{ | ||
'name': 'John', | ||
'number': '5555551234' | ||
|
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 |
---|---|---|
|
@@ -16,15 +16,14 @@ | |
author_email='[email protected]', | ||
packages=find_packages(exclude=['tests']), | ||
install_requires=[ | ||
'pyfiglet~=0.8', | ||
'click~=7.0', | ||
'pika~=1.1', | ||
'pyyaml~=5.4', | ||
'pymongo~=3.10', | ||
'pymysql~=0.9.3', | ||
'minio~=5.0.7', | ||
'redis~=3.5.3', | ||
'psycopg2-binary~=2.9.3' | ||
'pyfiglet>=0.8', | ||
'click>=8.1.7', | ||
'pika>=1.3.2', | ||
'pyyaml>=6.0.1', | ||
'pymongo>=4.6.1', | ||
'minio>=7.2.3', | ||
'redis>=5.0.1', | ||
'psycopg2-binary>=2.9.9' | ||
], | ||
entry_points={ | ||
'console_scripts': [ | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.