Contains simple contact form, which allows user submit messages (insert them into the database), display them.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
PHP 7.2.12
PHPStorm
Composer
Xampp
PHPUnit
SQLite3
-
Download files or clone "mail" repository.
-
Download and install Xampp. In ..\xampp\htdocs directory create a folder called "mailing". Copy project files into newly created ..\xampp\htdocs\mailing folder.
-
Initiate composer with composer init from ..\xampp\htdocs\mailing, make sure composer.json contains
"require-dev": { "phpunit/phpunit": "^7.0" }
-
Configure PHPUnit in PHPStorm (File>Settings>TestFrameworks), choose "Use composer autoloader" and set path to autoload.php, should be in mailing\vendor directory. Then in PHPStorm menu navigate to Run>Edit Configuration, click "+", add "PHPUnit" and set the directory to "xampp\htdocs\mailing\tests".
-
Start Apache server.
-
In browser of your choice go to "localhost\mailing"
Test folder is located in "tests\unit" directory.
- Maryna Kovalenko