Skip to content

Commit 8c4daad

Browse files
authored
W-14729590: Remove testmail key from robot tests (#107)
* Remove testmail key from robot tests * Update codeowners * Meaningless update to restart builds
1 parent 758718e commit 8c4daad

4 files changed

Lines changed: 1 addition & 47 deletions

File tree

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#ECCN: Open Source
22
#GUSINFO: NPC Orion, SFDO Outbound Funds Module
33
#
4-
# Copyright (c) 2021, salesforce.com, inc.
4+
# Copyright (c) 2021, salesforce.com, Inc.
55
# All rights reserved.
66
# SPDX-License-Identifier: BSD-3-Clause
77
# For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause

robot/OutboundFundsCommunity/resources/Email.py

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,13 @@
11
import random
2-
import requests
32
import re
43
import string
54
from BaseObjects import BaseOutboundFundsCommunityPage
65
from cumulusci.robotframework.utils import selenium_retry
76
from OutboundFundsCommunity import outboundfundscommunity_lex_locators
87

98

10-
endpoint = "https://api.testmail.app/api/json?apikey=cc5a1174-6d74-46d4-9ee9-409cc1da75d1&namespace=gms"
11-
12-
139
@selenium_retry
1410
class Email(BaseOutboundFundsCommunityPage):
15-
def get_reset_password_url(self, tag):
16-
"""Retrieves reset password URL from email sent to user"""
17-
params = {
18-
"tag": tag,
19-
}
20-
email_data = requests.get(endpoint, params=params, timeout=30)
21-
email_json = email_data.json()
22-
email_text = email_json["emails"][0]["text"]
23-
reset_password_url = re.search(r"(?P<url>https?://[^\s]+)", email_text).group(
24-
"url"
25-
)
26-
return reset_password_url
27-
28-
def verify_submit_application_email_received(self, tag):
29-
""""Verifies if user received the submit application email"""
30-
params = {
31-
"tag": tag,
32-
}
33-
email_data = requests.get(endpoint, params=params, timeout=60)
34-
email_json = email_data.json()
35-
email_subject = email_json["emails"][0]["text"]
36-
substring = "We’ve received your application and will be reviewing it soon"
37-
if substring in email_subject:
38-
pass
39-
else:
40-
raise Exception("Email not found")
41-
4211
def get_tag(self, email):
4312
split = re.split("[.@]", email)
4413
tag = split[1]

robot/OutboundFundsCommunity/tests/browser/FundingRequest/CommunityFundingRequest.robot

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,6 @@ Submit a New Funding Request
9393
Click Button Finish
9494
Current Page Should be Details Funding Request
9595

96-
#Verify Submit Application Email is Received
97-
# [Documentation] Verify if user receives email after
98-
# ... submitting application
99-
# [tags] feature:Funding Request
100-
# Verify Submit Application Email Received ${tag}
101-
10296
Edit a Submitted Request
10397
Go To Community As Robot Test User ${contact_id}
10498
Wait Until Element Is Visible text:Find Funding Opportunities

robot/OutboundFundsCommunity/tests/browser/Password/Password.robot

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,3 @@ Forgot Password
4646
Click Reset Password
4747
Current Page Should Be CheckPasswordResetEmail Community
4848

49-
Set Passsword
50-
[Documentation] Set new password for user
51-
[tags] feature:Password
52-
${reset_password_url} = Get Reset Password Url
53-
... ${tag}
54-
Set Suite Variable ${reset_password_url}
55-
Go To ${reset_password_url}
56-
Set New Password ${random_password}
57-
Current Page Should Be Home Community

0 commit comments

Comments
 (0)