2022-07-18 20:56:33 +00:00
|
|
|
|
|
|
|
from screens.StatusMainScreen import StatusMainScreen
|
|
|
|
from screens.StatusCommunityPortalScreen import StatusCommunityPortalScreen
|
|
|
|
from screens.StatusCommunityScreen import StatusCommunityScreen
|
|
|
|
|
2022-07-21 16:16:25 +00:00
|
|
|
_statusCommunityScreen = StatusCommunityScreen()
|
2022-07-18 20:56:33 +00:00
|
|
|
_statusCommunitityPortal = StatusCommunityPortalScreen()
|
|
|
|
_statusMainScreen = StatusMainScreen()
|
|
|
|
|
|
|
|
|
|
|
|
@Then("the user opens the community portal section")
|
|
|
|
def step(context: any):
|
|
|
|
_statusMainScreen.open_community_portal()
|
|
|
|
|
|
|
|
@Then("the user lands on the community portal section")
|
|
|
|
def step(context):
|
|
|
|
StatusCommunityPortalScreen()
|
|
|
|
|
|
|
|
@When("the user creates a community named |any|, with description |any|, intro |any| and outro |any|")
|
|
|
|
def step(context, community_name, community_description, community_intro, community_outro):
|
2022-07-21 16:16:25 +00:00
|
|
|
_statusCommunitityPortal.create_community(community_name, community_description, community_intro, community_outro)
|
2022-07-18 20:56:33 +00:00
|
|
|
|
|
|
|
@Then("the user lands on the community named |any|")
|
|
|
|
def step(context, community_name):
|
2022-07-21 16:16:25 +00:00
|
|
|
StatusCommunityScreen()
|
|
|
|
_statusCommunityScreen.verify_community_name(community_name)
|
|
|
|
|
2022-07-25 20:30:34 +00:00
|
|
|
@When("the admin creates a community channel named |any|, with description |any| with the method |any|")
|
|
|
|
def step(context, community_channel_name, community_channel_description, method):
|
|
|
|
_statusCommunityScreen.create_community_channel(community_channel_name, community_channel_description, method)
|
2022-07-21 16:16:25 +00:00
|
|
|
|
2022-08-03 20:16:43 +00:00
|
|
|
@When("the admin edits the current community channel to the name |any|")
|
|
|
|
def step(context, new_community_channel_name):
|
|
|
|
_statusCommunityScreen.edit_community_channel(new_community_channel_name)
|
2022-07-25 17:15:02 +00:00
|
|
|
|
2022-07-21 16:16:25 +00:00
|
|
|
@Then("the user lands on the community channel named |any|")
|
|
|
|
def step(context, community_channel_name):
|
2022-08-03 20:16:43 +00:00
|
|
|
_statusCommunityScreen.verify_channel_name(community_channel_name)
|
|
|
|
|
|
|
|
@When("the admin edits the current community to the name |any| and description |any| and color |any|")
|
|
|
|
def step(context, new_community_name, new_community_description, new_community_color):
|
|
|
|
_statusCommunityScreen.edit_community(new_community_name, new_community_description, new_community_color)
|
|
|
|
|
|
|
|
@When("the admin goes back to the community")
|
|
|
|
def step(context):
|
|
|
|
_statusCommunityScreen.go_back_to_community()
|
|
|
|
|