GithubHelp home page GithubHelp logo

fejan92 / exercism_php Goto Github PK

View Code? Open in Web Editor NEW

This project forked from exercism/php

0.0 0.0 0.0 1.89 MB

Exercism exercises in PHP.

Home Page: https://exercism.org/tracks/php

License: MIT License

Shell 0.87% PHP 99.08% Smarty 0.05%

exercism_php's Introduction

Exercism PHP Track

Exercism exercises in PHP

Follow these instructions to contribute to the PHP track. To solve the exercises, head to the PHP track and check the documentation.

Install Dependencies

The following system dependencies are required:

Run the following command to get started with this project:

composer install # Required dependencies to develop this track

Running Exercism resources management

bin/configlet is the official tool for managing Exercism language track repositories. See Building Exercism docs.

For convenience, you can use composer configlet:fmt to fix formatting issues in the Exercism track files. This is included in composer ci to run the CI checks locally.

Running Unit Test Suite

The tests are run with PHPUnit. A shell loop injecting exemplar.php is provided to ease testing.

Execute the following command to run the tests:

composer test:run

This is included in composer ci to run the CI checks locally.

Running Style Checker

This project uses a slightly modified version of PSR-12. Use the following commands to apply code style:

composer lint:check # Checks the files against the code style rules
composer lint:fix # Automatically fix code style issues

The lint:check is included in composer ci to run the CI checks locally.

Contributing

  • Read the documentation at Exercism.
  • Follow the PSR-12 coding style (Exercisms PHP track uses a slightly modified version of PSR-12).
  • Run composer ci to run CI checks locally before pushing.
  • CI is run on all pull requests, it must pass the required checks for merge.
  • CI is running all tests on PHP 8.0 to PHP 8.2 for Linux, Windows and MacOS.

Generating new practice exercises

Use bin/configlet create --practice-exercise <slug> to create the exercism resources required. This provides you with the directories and files in exercises/practice/<slug>. Look into tests.toml for which test cases not to implement / generate and mark them with include = false.

Test generator MVP used like this:

composer -d contribution/generator install
contribution/generator/bin/console app:create-tests '<slug>'
composer lint:fix

exercism_php's People

Contributors

kytrinyx avatar petemcfarlane avatar erikschierboom avatar mk-mxp avatar neenjaw avatar dependabot[bot] avatar michaelbunker avatar tomasnorre avatar arueckauer avatar fejan-malek avatar exercism-bot avatar wilmoore avatar camilopayan avatar dstockto avatar zembrowski avatar arthurchipdean avatar vnkmpf avatar homersimpsons avatar rossbearman avatar jrdnull avatar hrumpa avatar cmccandless avatar dkinzer avatar dog avatar brettsantore avatar g-rath avatar codedge avatar kk-r avatar meganos avatar pmatseykanets avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.