Hide
Test Requirements
For these tests you will need:
- outbound mail to be correctly configured and working on your system;
- a test e-mail account (Andrew can provide you with details of one, or you can create a new Gmail account)
Initial setup
- Setup VERP handling:
- Open Site administration -> Server -> Incoming mail configuration -> Mail settings
- Enable incoming mail processing;
- Add your inbound mailbox details
- Save changes
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Enable the private files handler
- Reduce the max editing time of your forum messages to preserve testing sanity
- Open Site administration -> Security -> Site policies
- Set the maxediting time to 1 minute
- Create a new course
- Enrol a couple of users - you probably only want one; or two
- Create a new forum in that course - choose auto subscription
Forum tests
The following forum tests are all fairly similar. They differ in some minor details:
- The Sender address; and
- The setting for the handler on whether to verify this address
Note: These tests need to be run both with plaintext emails, and HTML e-mails.
Note: Please try including attachments within your message
Note: There are two types of e-mail attachment: Inline (typically images inline with text), and attachment (as an attachment to the whole message). Please use both.
Forum test 1
- Create a new post in your forum; wait a minute; run cron to send the forum e-mail
- Check your e-mail. You should have received an e-mail for each of the enrolled users.
- Reply to the message as your first user
- Note: The sender e-mail address must be correct and must match the address in the user profile
- Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
- Send your message
- Wait a minute, then run cron again. Alternatively, just run the pickup task:
php ./admin/tool/task/cli/schedule_task.php --execute=\\tool_messageinbound\\task\\pickup_task
|
- Confirm the blissful absence of error messages in the cron task
- Confirm that the message was posted in the forum
Forum test 2
- Reply to the message as your first user again
- This time, use a different sender address (e.g. an alias)
- Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
- Send your message
- Wait a minute, then run pickup task again
- Confirm the blissful absence of error messages in the cron task
- Confirm that the message was not posted into the forum
- Check your e-mail again and you should have a new message from Moodle
- Reply to the message as the correct e-mail address for the user
- Run the pickup task again
- Confirm the blissful absence of error messages in the cron task
- Confirm that the message was posted in the forum
Forum test 3
- Reply to the message as your first user again
- This time, use a different sender address (e.g. an alias)
- Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
- Send your message
- Wait a minute, then run pickup task again
- Confirm the blissful absence of error messages in the cron task
- Confirm that the message was not posted into the forum
- Check your e-mail again and you should have a new message from Moodle
- Reply to the message as the incorrect e-mail address for the user again
- Run the pickup task again
- Confirm the blissful absence of error messages in the cron task
- Confirm that the message was posted in the forum
Forum test 4
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Edit the forum handler and set:
- Require validation: false
- Reply to the message as your first user again
- This time, use a different sender address (e.g. an alias)
- Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
- Send your message
- Wait a minute, then run pickup task again
- Confirm the blissful absence of error messages in the cron task
- Confirm that the message was posted in the forum
Forum test 5
-
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Disable the mod_forum handler
- Reply to the message as your first user again
- Wait a minute, then run pickup task again
- Confirm that the message was NOT posted in the forum
- Confirm that you received a reply informing you that the handler was disabled
Private Files
- Open Navigation -> My profile -> My private files
- Confirm that no e-mail address is shown on the private files page
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Enable the mod_forum handler
- Open Navigation -> My profile -> My private files
- Confirm that an e-mail address is now shown on the private files page
As the correct user
- Send an e-mail to the address provided, using the correct sender address for that moodle user
- Include attachments, both inline and as attachments
- Run pickup task
- Confirm the blissful absence of error messages in the cron task
- Confirm that your file was uploaded to private files
With a different e-mail address
- Send an e-mail to the address provided, using a different e-mail address
- Include attachments, both inline and as attachments
- Run pickup task
- Confirm the blissful absence of error messages in the cron task
- Confirm that your file was not uploaded to private files
- Check your e-mail again and you should have a new message from Moodle
- Reply to the message as the incorrect e-mail address for the user again
- Run the pickup task again
- Confirm the blissful absence of error messages in the cron task
- Confirm that your file was uploaded to private files
Without requiring validation
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Edit the private files handler and set:
- Require validation: false
- Send an e-mail to the address provided, using the correct sender address for that moodle user
- Include attachments, both inline and as attachments
- Run pickup task
- Confirm the blissful absence of error messages in the cron task
- Confirm that your file was uploaded to private files
- Send an e-mail to the address provided, using a different e-mail address
- Include attachments, both inline and as attachments
- Run pickup task
- Confirm the blissful absence of error messages in the cron task
- Confirm that your file was uploaded to private files
Disabling handler
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Edit the private files handler and set:
- Require validation: true
- Send an e-mail to the address provided, using a different e-mail address
- Include attachments, both inline and as attachments
- Run pickup task
- Confirm the blissful absence of error messages in the cron task
- Confirm that your file was not uploaded to private files
- Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
- Disable the private files handler
- Check your e-mail again and you should have a new message from Moodle
- Reply to the message to confirm the authenticity
- Run pickup task
- Confirm that your file was not uploaded to private files
- Confirm that you received a reply informing you that the handler was disabled
Show
Test Requirements
For these tests you will need:
outbound mail to be correctly configured and working on your system;
a test e-mail account (Andrew can provide you with details of one, or you can create a new Gmail account)
Initial setup
Setup VERP handling:
Open Site administration -> Server -> Incoming mail configuration -> Mail settings
Enable incoming mail processing;
Add your inbound mailbox details
Save changes
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Enable the private files handler
Reduce the max editing time of your forum messages to preserve testing sanity
Open Site administration -> Security -> Site policies
Set the maxediting time to 1 minute
Create a new course
Enrol a couple of users - you probably only want one; or two
Create a new forum in that course - choose auto subscription
Forum tests
The following forum tests are all fairly similar. They differ in some minor details:
The Sender address; and
The setting for the handler on whether to verify this address
Note: These tests need to be run both with plaintext emails, and HTML e-mails.
Note: Please try including attachments within your message
Note: There are two types of e-mail attachment: Inline (typically images inline with text), and attachment (as an attachment to the whole message). Please use both.
Forum test 1
Create a new post in your forum; wait a minute; run cron to send the forum e-mail
Check your e-mail. You should have received an e-mail for each of the enrolled users.
Reply to the message as your first user
Note: The sender e-mail address must be correct and must match the address in the user profile
Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
Send your message
Wait a minute, then run cron again. Alternatively, just run the pickup task:
php ./admin/tool/task/cli/schedule_task.php --execute=\\tool_messageinbound\\task\\pickup_task
Confirm the blissful absence of error messages in the cron task
Confirm that the message was posted in the forum
Forum test 2
Reply to the message as your first user again
This time, use a different sender address (e.g. an alias)
Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
Send your message
Wait a minute, then run pickup task again
Confirm the blissful absence of error messages in the cron task
Confirm that the message was not posted into the forum
Check your e-mail again and you should have a new message from Moodle
Reply to the message as the correct e-mail address for the user
Run the pickup task again
Confirm the blissful absence of error messages in the cron task
Confirm that the message was posted in the forum
Forum test 3
Reply to the message as your first user again
This time, use a different sender address (e.g. an alias)
Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
Send your message
Wait a minute, then run pickup task again
Confirm the blissful absence of error messages in the cron task
Confirm that the message was not posted into the forum
Check your e-mail again and you should have a new message from Moodle
Reply to the message as the incorrect e-mail address for the user again
Run the pickup task again
Confirm the blissful absence of error messages in the cron task
Confirm that the message was posted in the forum
Forum test 4
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Edit the forum handler and set:
Require validation: false
Reply to the message as your first user again
This time, use a different sender address (e.g. an alias)
Note: If using gmail, you may need to copy/paste the reply-to address from gmail because GMail are sucky
Send your message
Wait a minute, then run pickup task again
Confirm the blissful absence of error messages in the cron task
Confirm that the message was posted in the forum
Forum test 5
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Disable the mod_forum handler
Reply to the message as your first user again
Wait a minute, then run pickup task again
Confirm that the message was NOT posted in the forum
Confirm that you received a reply informing you that the handler was disabled
Private Files
Open Navigation -> My profile -> My private files
Confirm that no e-mail address is shown on the private files page
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Enable the mod_forum handler
Open Navigation -> My profile -> My private files
Confirm that an e-mail address is now shown on the private files page
As the correct user
Send an e-mail to the address provided, using the correct sender address for that moodle user
Include attachments, both inline and as attachments
Run pickup task
Confirm the blissful absence of error messages in the cron task
Confirm that your file was uploaded to private files
With a different e-mail address
Send an e-mail to the address provided, using a different e-mail address
Include attachments, both inline and as attachments
Run pickup task
Confirm the blissful absence of error messages in the cron task
Confirm that your file was not uploaded to private files
Check your e-mail again and you should have a new message from Moodle
Reply to the message as the incorrect e-mail address for the user again
Run the pickup task again
Confirm the blissful absence of error messages in the cron task
Confirm that your file was uploaded to private files
Without requiring validation
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Edit the private files handler and set:
Require validation: false
Send an e-mail to the address provided, using the correct sender address for that moodle user
Include attachments, both inline and as attachments
Run pickup task
Confirm the blissful absence of error messages in the cron task
Confirm that your file was uploaded to private files
Send an e-mail to the address provided, using a different e-mail address
Include attachments, both inline and as attachments
Run pickup task
Confirm the blissful absence of error messages in the cron task
Confirm that your file was uploaded to private files
Disabling handler
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Edit the private files handler and set:
Require validation: true
Send an e-mail to the address provided, using a different e-mail address
Include attachments, both inline and as attachments
Run pickup task
Confirm the blissful absence of error messages in the cron task
Confirm that your file was not uploaded to private files
Open Site administration -> Server -> Incoming mail configuration -> Message Handlers
Disable the private files handler
Check your e-mail again and you should have a new message from Moodle
Reply to the message to confirm the authenticity
Run pickup task
Confirm that your file was not uploaded to private files
Confirm that you received a reply informing you that the handler was disabled