-
Notifications
You must be signed in to change notification settings - Fork 1
Add docker structure #13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
151 commits
Select commit
Hold shift + click to select a range
50caea6
Добавил контейнер с Postgres
507fb9f
- Добавил контейнер с nginx,php-fpm и postgres.
KarlsonComplete 6473c92
- Добавил расширения mbstring,zip,curl,bcmath
KarlsonComplete 4c2f9b9
Merge pull request #12 from KarlsonComplete/add-docker-structure
mesilov ef8ab43
Add PHP CLI service and improve Docker setup
mesilov 5cff2ea
- Добавил глобальные переменные
KarlsonComplete 6d8d5bd
Add UUID and member ID properties to Bitrix24Account
mesilov 85dafa1
Refactor Docker setup and Bitrix24Account entity
mesilov 1eed785
Update .gitignore to exclude /docker/postgres directory.
mesilov 1ecbe1c
Add custom repository to Bitrix24Account
mesilov ace9189
Add functional test for Bitrix24AccountRepository
mesilov 85ceeb4
Remove /docker/postgres from .gitignore
mesilov e6c002b
Refactor repository and entity manager usage.
mesilov f442bad
Update PHPStan command in GitHub Actions workflow
mesilov 5817e70
Update Rector command in GitHub workflow
mesilov 93ad32a
Create functional test workflow and update configurations
mesilov 1a9bb10
Switch to direct phpunit command for unit tests
mesilov 5aaedd7
Update functional test workflow to include DB setup
mesilov 6fce03d
Update DB env variables in workflow configuration
mesilov 9030702
Add database configuration to functional test workflow
mesilov 00d16ba
Add new use cases for Bitrix24 account management
mesilov 32803bd
Remove redundant flush argument from save method
mesilov 57be1b9
Refactor repository methods to include PHPStan type hints
mesilov c096193
Refactor account handling logic in multiple use cases
mesilov 58c1672
- Стянул изменения из основного репозитория
KarlsonComplete cd2d460
- Добавил мапинг на столбцы: isBitrix24UserAdmin,domain_url,updatedAt…
KarlsonComplete 01ad508
- Добавил мапинг на столбец: accountStatus.
KarlsonComplete ce7121f
Merge pull request #14 from KarlsonComplete/add-docker-structure
mesilov 1e56504
- Добавил Flusher.php
KarlsonComplete 04c6547
- Добавил в тестах при создании экземпляра Bitrix24AccountRepository …
KarlsonComplete 22baa6e
- Добавил отображения структуры бд (где это отображается?)
KarlsonComplete a29c2e6
- Создал xml файл для маппинга.
KarlsonComplete 5f2d755
Merge pull request #15 from KarlsonComplete/add-docker-structure
mesilov 6a7b8a9
- Убрал из namespace sdk
KarlsonComplete 5327b7b
- Переименовал xml файлы для маппинга
KarlsonComplete ba737ec
- Перенес Flusher
KarlsonComplete 0546e6d
- Добавил маппинг AuthToken для сущности Bitrix24Account
KarlsonComplete 7eef687
Merge pull request #16 from KarlsonComplete/add-docker-structure
mesilov 22e2931
Update bitrix24/b24phpsdk dependency version
mesilov a0135c2
Add PHP-CS-Fixer configuration and update dependencies
mesilov f4992ab
Add GitHub Actions for PHP CS-Fixer
mesilov 0ec7bbc
Enhance PHP-CS-Fixer configuration with additional rules
mesilov 9c99e2a
- Добавил маппинг Scope для сущности Bitrix24Account
KarlsonComplete 0ba4a98
- Поменял название id на uuid в сущности и в маппинге
KarlsonComplete 4aa62ae
Merge pull request #17 from KarlsonComplete/add-docker-structure
mesilov 984c7a1
- Получается добавлять в таблицу
KarlsonComplete f3bf322
Merge pull request #18 from KarlsonComplete/add-docker-structure
mesilov 620a437
Add environment variable loading and debugging support
mesilov 4ce759c
Add functional test for ChangeDomainUrl handler
mesilov dc596ea
Add flusher support to InstallFinish handler
mesilov 04297f7
Add functional test for InstallStart handler
mesilov c365b9f
Remove custom exception and update handler logic
mesilov db13570
Remove SaveAccount use case and add proper Uninstall testing
mesilov 87639e7
Add TraceableEventDispatcher to HandlerTests
mesilov 3137510
Update test to check for domain URL change event
mesilov 7467889
Remove unused import in HandlerTest.php
mesilov fc01b55
- Убрал автогенерацию
KarlsonComplete 0d169d3
- Поменял тип в маппинге с datetime_immutable на carbon_immutable
KarlsonComplete 11e381f
Merge pull request #19 from KarlsonComplete/add-docker-structure
mesilov 37aea9a
- Убрал в аккаунте атрибуты
KarlsonComplete 21f10f6
Merge pull request #20 from KarlsonComplete/add-docker-structure
mesilov 5340ec8
Add FlusherDecorator for functional tests
mesilov 33f6356
Refactor and enforce input validation in Bitrix24AccountRepository
mesilov e648cba
Fix formatting and simplify tests
mesilov 9890d0a
- Добавил xdebug
KarlsonComplete 15033e7
Merge pull request #21 from KarlsonComplete/add-docker-structure
KarlsonComplete 969782e
Refactor repository methods and improve exception handling
mesilov 21d34d3
Refactor exception formatting for readability
mesilov 469e563
Refactor event dispatching mechanism
mesilov 57153ae
Refactor `Handler.php` files for code clarity and maintainability
mesilov 9ad0581
Refactor event dispatching mechanism
mesilov 22b58ab
- Поменял подход к получению authToken
KarlsonComplete 959aaaa
- Добавил сообщения для проверок в тестах
KarlsonComplete a67cb48
- Добавил Fetcher тест
KarlsonComplete e9817e1
Merge pull request #22 from KarlsonComplete/add-docker-structure
mesilov f082b16
- Война с AggregateRoot
KarlsonComplete e6a6977
- Внес правки для AggregateRoot
KarlsonComplete ba7575a
- Добавил исключение в метод getById
KarlsonComplete 57a3f51
- Тест на фетчер
KarlsonComplete a27c75e
Merge pull request #23 from KarlsonComplete/add-docker-structure
mesilov 9e936c7
- Правки на scope
KarlsonComplete 899cae3
Merge pull request #24 from KarlsonComplete/add-docker-structure
mesilov 59e34a5
Simplify application scope handling
mesilov d6b58a1
Update PHP SDK in test commands
mesilov 9f5f133
Update Composer flags to prefer source in workflows
mesilov 7e3727c
Add #[Override] attribute and refactor variable names
mesilov 20b211a
Fix variable name in RenewAuthToken handler
mesilov ff81205
Update Composer flags and add specific package update
mesilov 8fcc00d
Reorder composer update commands in CI workflow
mesilov c7ec28e
Reorder composer update commands.
mesilov b81e375
Reorder composer update commands.
mesilov bfd6256
Add step to install b24-php-sdk from source
mesilov 28667e6
Update SDK installation method in GitHub Actions workflow
mesilov 7059b84
Update SDK installation method in GitHub Actions workflow
mesilov 84568ed
Update composer flags and install b24-php-sdk from source
mesilov d684661
Fix b24phpsdk installation naming and add to lint workflow
mesilov ff5fa2d
Refactor and streamline codebase
mesilov a70123d
Remove redundant b24phpsdk source installation steps.
mesilov a2b6dfd
Remove prefer-dist flag from Composer command
mesilov 3b31045
Remove prefer-dist from COMPOSER_FLAGS in CI workflow.
mesilov f697703
Remove xdebug from PHPUnit command in Makefile
mesilov 17555c1
Add GitHub workflow for license checking
mesilov bd63bba
Remove PHP 8.2 from license check workflow
mesilov b1cdf4e
- Починил Fetcher тест
KarlsonComplete be68b22
- Переписал flusher и переписал
KarlsonComplete 65413da
Merge pull request #25 from KarlsonComplete/add-docker-structure
mesilov 70f2c9f
- Поправил тест на изменения url домена
KarlsonComplete 9f1ee0c
- Поправил тесты
KarlsonComplete 50733f5
- Изменил нейминг фетчера для битрикс24аккаунта.
KarlsonComplete 9a6e0e8
..
KarlsonComplete 6046515
Merge pull request #27 from KarlsonComplete/add-docker-structure
mesilov 64044c6
Поправил тесты и ошибки с phpstan
KarlsonComplete dde051e
.
KarlsonComplete 47f3ffd
.
KarlsonComplete 4d2bda7
Merge pull request #29 from KarlsonComplete/add-docker-structure
mesilov 129e83b
Правки
KarlsonComplete ae0d1a5
Правки
KarlsonComplete 2535f7b
Добавил 2 юнит теста
KarlsonComplete 9a83c79
Добавил 2 юнит теста
KarlsonComplete 98eb191
Правки в тест на повторную установку аккаунта
KarlsonComplete 92347d8
Правки в тест на повторную установку аккаунта
KarlsonComplete bb8e9c7
Merge pull request #32 from KarlsonComplete/add-docker-structure
camaxtly 56eb727
- Добавил датаправайдер в одном из тестов на команду.
KarlsonComplete a33d77f
- Добавил генератор для всех тестов
KarlsonComplete 81a40a8
- юзанул cs-fixer
KarlsonComplete 3fb5766
- юзанул cs-fixer для тестов
KarlsonComplete 31e9be2
Merge pull request #34 from KarlsonComplete/add-docker-structure
camaxtly 9b5f78c
- Правки для домена
KarlsonComplete 0af10a0
- Правки для фукнциональных тестов
KarlsonComplete f109090
- Пытаюсь править для функциональных тестов в github actions
KarlsonComplete 3a9b261
- Тест на проверку функции домена
KarlsonComplete 8d149d4
Update tests-functional.yml
KarlsonComplete ecd22a6
- Правим github actions
KarlsonComplete 9e04451
- Правим github actions
KarlsonComplete af668ea
- Правим github actions
KarlsonComplete c2bfeb6
- Юзанули ректор
KarlsonComplete b27b0cb
- Правки для github actions
KarlsonComplete 1e993a4
- Правки для github actions
KarlsonComplete 0c1e899
- Правки для github actions 2
KarlsonComplete 86ff567
- Правки для github actions 3
KarlsonComplete 2765344
- Правки для тестов
KarlsonComplete c7a4d8b
- Правки для сs fixer
KarlsonComplete 33eb305
Merge pull request #36 from KarlsonComplete/add-docker-structure
camaxtly 681a05e
- Перенес функцию на проверку домена в отдельный тест
KarlsonComplete 48173d7
- Поправил тесты
KarlsonComplete d754288
- Поправил сущность аккаунта , добавил параметры для метода updateApp…
KarlsonComplete 3363ca6
Merge pull request #37 from KarlsonComplete/add-docker-structure
camaxtly 556720d
- Поправил домен
KarlsonComplete c80df26
- Поправил домен
KarlsonComplete 024e691
- Добавил useCase на обновления версии и написал тесты
KarlsonComplete 61f7293
Merge pull request #38 from KarlsonComplete/add-docker-structure
camaxtly File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| <?php | ||
|
|
||
| declare(strict_types=1); | ||
|
|
||
| use Lendable\ComposerLicenseChecker\LicenseConfigurationBuilder; | ||
|
|
||
| return (new LicenseConfigurationBuilder()) | ||
| ->addLicenses( | ||
| // And other licenses you wish to allow. | ||
| 'MIT', | ||
| 'Apache-2.0', | ||
| 'BSD-3-Clause', | ||
| ) | ||
| ->build(); |
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| # In all environments, the following files are loaded if they exist, | ||
| # the latter taking precedence over the former: | ||
| # | ||
| # * .env contains default values for the environment variables needed by the app | ||
| # * .env.local uncommitted file with local overrides | ||
| # * .env.$APP_ENV committed environment-specific defaults | ||
| # * .env.$APP_ENV.local uncommitted environment-specific overrides | ||
| # | ||
| # Real environment variables win over .env files. | ||
| # | ||
| # DO NOT DEFINE PRODUCTION SECRETS IN THIS FILE NOR IN ANY OTHER COMMITTED FILES. | ||
| # | ||
| # Run "composer dump-env prod" to compile .env files for production use (requires symfony/flex >=1.2). | ||
| # https://symfony.com/doc/current/best_practices.html#use-environment-variables-for-infrastructure-configuration | ||
| DATABASE_HOST= | ||
| DATABASE_USER= | ||
| DATABASE_PASSWORD= | ||
| DATABASE_NAME= |
File renamed without changes.
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| name: "Allowed licenses checks" | ||
| on: | ||
| push: | ||
| pull_request: | ||
|
|
||
| jobs: | ||
| static-analysis: | ||
| name: "composer-license-checker" | ||
| runs-on: ${{ matrix.operating-system }} | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| php-version: | ||
| - "8.3" | ||
| dependencies: [ highest ] | ||
| operating-system: [ ubuntu-latest] | ||
|
|
||
| steps: | ||
| - name: "Checkout" | ||
| uses: "actions/checkout@v2" | ||
|
|
||
| - name: "Install PHP" | ||
| uses: "shivammathur/setup-php@v2" | ||
| with: | ||
| coverage: "none" | ||
| php-version: "${{ matrix.php-version }}" | ||
| extensions: json, bcmath, curl, intl, mbstring | ||
| tools: composer:v2 | ||
|
|
||
| - name: "Install lowest dependencies" | ||
| if: ${{ matrix.dependencies == 'lowest' }} | ||
| run: "composer update --prefer-lowest --no-interaction --no-progress --no-suggest" | ||
|
|
||
| - name: "Install highest dependencies" | ||
| if: ${{ matrix.dependencies == 'highest' }} | ||
| run: "composer update --no-interaction --no-progress --no-suggest" | ||
|
|
||
| - name: "composer-license-checker" | ||
| run: "make lint-allowed-licenses" | ||
|
|
||
| - name: "is allowed licenses check succeeded" | ||
| if: ${{ success() }} | ||
| run: | | ||
| echo '✅ allowed licenses check pass, congratulations!' | ||
|
|
||
| - name: "is allowed licenses check failed" | ||
| if: ${{ failure() }} | ||
| run: | | ||
| echo '::error:: ❗️ allowed licenses check failed (╯°益°)╯彡┻━┻' |
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,51 @@ | ||
| on: | ||
| push: | ||
| pull_request: | ||
|
|
||
| name: Lint CS-Fixer | ||
|
|
||
| jobs: | ||
| static-analysis: | ||
| name: "CS-Fixer" | ||
| runs-on: ${{ matrix.operating-system }} | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| php-version: | ||
| - "8.3" | ||
| dependencies: [ highest ] | ||
| operating-system: [ ubuntu-latest] | ||
|
|
||
| steps: | ||
| - name: "Checkout" | ||
| uses: "actions/checkout@v2" | ||
|
|
||
| - name: "Install PHP" | ||
| uses: "shivammathur/setup-php@v2" | ||
| with: | ||
| coverage: "none" | ||
| php-version: "${{ matrix.php-version }}" | ||
| extensions: json, bcmath, curl, intl, mbstring | ||
| tools: composer:v2 | ||
|
|
||
| - name: "Install lowest dependencies" | ||
| if: ${{ matrix.dependencies == 'lowest' }} | ||
| run: "composer update --prefer-lowest --no-interaction --no-progress --no-suggest" | ||
|
|
||
| - name: "Install highest dependencies" | ||
| if: ${{ matrix.dependencies == 'highest' }} | ||
| run: "composer update --no-interaction --no-progress --no-suggest" | ||
|
|
||
| - name: "CS-Fixer" | ||
| run: "vendor/bin/php-cs-fixer fix --dry-run --diff --verbose" | ||
|
|
||
| - name: "is CS-Fixer check succeeded" | ||
| if: ${{ success() }} | ||
| run: | | ||
| echo '✅ CS-Fixer check pass, congratulations!' | ||
|
|
||
| - name: "is CS-Fixer check failed" | ||
| if: ${{ failure() }} | ||
| run: | | ||
| echo '::error:: ❗️ CS-Fixer check failed (╯°益°)╯彡┻━┻' |
This file contains hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
| @@ -0,0 +1,86 @@ | ||
| name: "Functional tests" | ||
|
|
||
| on: | ||
| push: | ||
| pull_request: | ||
|
|
||
| env: | ||
| COMPOSER_FLAGS: "--ansi --no-interaction --no-progress" | ||
| DATABASE_HOST: localhost | ||
| DATABASE_USER: b24phpLibTest | ||
| DATABASE_PASSWORD: b24phpLibTest | ||
| DATABASE_NAME: b24phpLibTest | ||
|
|
||
| jobs: | ||
| tests: | ||
| name: "Functional tests" | ||
|
|
||
| runs-on: ${{ matrix.operating-system }} | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| php-version: | ||
| - "8.3" | ||
| dependencies: [ highest ] | ||
| operating-system: [ ubuntu-latest ] | ||
| services: | ||
| bitrix24-php-lib-test-database: | ||
| image: postgres:16-alpine | ||
| ports: | ||
| - 5432:5432 | ||
| options: >- | ||
| --health-cmd="pg_isready -U b24phpLibTest" | ||
| --health-interval=10s | ||
| --health-timeout=5s | ||
| --health-retries=5 | ||
| env: | ||
| POSTGRES_USER: b24phpLibTest | ||
| POSTGRES_PASSWORD: b24phpLibTest | ||
| POSTGRES_DB: b24phpLibTest | ||
|
|
||
| steps: | ||
| - name: "Checkout code" | ||
| uses: "actions/checkout@v2" | ||
|
|
||
| - name: "Setup PHP" | ||
| uses: "shivammathur/setup-php@v2" | ||
| with: | ||
| coverage: "none" | ||
| php-version: "${{ matrix.php-version }}" | ||
| extensions: json, bcmath, curl, intl, mbstring, pdo_pgsql, pdo | ||
|
|
||
| - name: "Install dependencies with Composer" | ||
| run: | | ||
| composer update ${{ env.COMPOSER_FLAGS }} | ||
|
|
||
| - name: "Install PostgreSQL client" | ||
| run: | | ||
| sudo apt-get update | ||
| sudo apt-get install -y postgresql-client | ||
|
|
||
| - name: "Wait for PostgreSQL to be ready" | ||
| run: | | ||
| until pg_isready -h localhost -p 5432 -U b24phpLibTest; do | ||
| echo "Waiting for PostgreSQL to start..." | ||
| sleep 2 | ||
| done | ||
|
|
||
| - name: "Run functional tests" | ||
| run: | | ||
| php bin/doctrine orm:schema-tool:drop --force | ||
| php bin/doctrine orm:schema-tool:create --dump-sql | ||
| php bin/doctrine orm:schema-tool:update --force | ||
| php bin/doctrine orm:info | ||
| # Запуск тестов с очисткой состояния между тестами | ||
| php vendor/bin/phpunit --testsuite=functional_tests --display-warnings --testdox --process-isolation | ||
|
|
||
| - name: "is functional tests succeeded" | ||
| if: ${{ success() }} | ||
| run: | | ||
| echo '✅ functional tests pass, congratulations!' | ||
|
|
||
| - name: "is functional tests failed" | ||
| if: ${{ failure() }} | ||
| run: | | ||
| echo '::error:: ❗️ functional tests failed (╯°益°)╯彡┻━┻' | ||
This file contains hidden or 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 hidden or 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,8 +1,10 @@ | ||
| /.idea* | ||
| /vendor | ||
| /.cache | ||
| /docker/db | ||
| composer.phar | ||
| composer.lock | ||
| .phpunit.result.cache | ||
| *.log | ||
| .env.local | ||
| .env.local | ||
| *.cache |
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| <?php | ||
|
|
||
| declare(strict_types=1); | ||
| use PhpCsFixer\Config; | ||
| use PhpCsFixer\Finder; | ||
| use PhpCsFixer\Runner\Parallel\ParallelConfigFactory; | ||
|
|
||
| $finder = Finder::create() | ||
| ->in(__DIR__.'/src'); | ||
|
|
||
| return (new Config()) | ||
| ->setParallelConfig(ParallelConfigFactory::detect()) | ||
| ->setCacheFile(__DIR__.'/.php-cs-fixer.cache') | ||
| ->setFinder($finder) | ||
| ->setRules([ | ||
| '@Symfony' => true, | ||
| '@DoctrineAnnotation' => true, | ||
| '@PhpCsFixer' => true, | ||
| 'phpdoc_to_comment' => false, | ||
| ]); |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.