-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9f2ebe0
commit 2ff52a8
Showing
15 changed files
with
5 additions
and
200 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 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 |
---|---|---|
@@ -1,9 +1,5 @@ | ||
from portal.forms.dotmailer import DonateForm, NewsletterForm | ||
from portal.forms.dotmailer import NewsletterForm | ||
|
||
|
||
def process_newsletter_form(request): | ||
return {"news_form": NewsletterForm()} | ||
|
||
|
||
def process_donate_form(request): | ||
return {"donate_form": DonateForm()} |
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
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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1 @@ | ||
/// <reference types="cypress" /> | ||
|
||
describe('User', () => { | ||
it('can open donate popup', () => { | ||
cy.visit("/"); | ||
cy.get('#donate').click(); | ||
cy.get('.popup-box').should('be.visible'); | ||
cy.get('#donate_form').should('be.visible'); | ||
}); | ||
}); | ||
/// <reference types="cypress" /> |
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,19 +18,3 @@ def test_newsletter_signup_fail(self): | |
response = client.post(url, data) | ||
messages = list(response.wsgi_request._messages) | ||
assert len([m for m in messages if "error" in m.tags]) == 1 | ||
|
||
def test_donate_signup_successful(self): | ||
url = reverse("process_donate_form") | ||
client = Client() | ||
data = {"email": "[email protected]", "age_verification": "on"} | ||
response = client.post(url, data) | ||
messages = list(response.wsgi_request._messages) | ||
assert len([m for m in messages if m.tags == "success"]) == 1 | ||
|
||
def test_donate_signup_fail(self): | ||
url = reverse("process_donate_form") | ||
client = Client() | ||
data = {"email": "invalid_email", "age_verification": "on"} | ||
response = client.post(url, data) | ||
messages = list(response.wsgi_request._messages) | ||
assert len([m for m in messages if "error" in m.tags]) == 1 |
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