Author Topic: how to use phpunit in a project  (Read 3400 times)

Offline zhaozhi

  • Newbie
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
how to use phpunit in a project
« on: September 22, 2022, 02:14:06 AM »
there is no phpunit in my projec. Now I want to konw how to use phpunit  in my project. I have never used phpunit

Offline Basara

  • Administrator
  • Hero Member
  • *****
  • Posts: 5774
  • Karma: +274/-2
    • View Profile
Re: how to use phpunit in a project
« Reply #1 on: September 22, 2022, 07:16:47 AM »
Hello.

Your question is not clear can you describe where your want to use PHP input in AbanteCart

Offline Hayes1

  • Newbie
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: how to use phpunit in a project
« Reply #2 on: December 30, 2023, 05:56:21 AM »
Embarking on a PHPUnit journey is a great initiative! To integrate it into your project, start by installing PHPUnit via Composer, create test classes, and write test methods to validate your code. The learning curve is rewarding, and you'll soon appreciate the robust testing capabilities it brings to your development workflow.

Offline abolabo

  • core-developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 2046
  • Karma: +318/-13
  • web for all, all for web!
    • View Profile
    • AbanteCart
Re: how to use phpunit in a project
« Reply #3 on: December 31, 2023, 11:41:35 AM »
you can check how we use phpunit testing in the abantecart next generation.
See this file tree https://github.com/abantecart/abantecart_2.0/tree/master/abantecart/abc
You can find phpunit configuration file https://github.com/abantecart/abantecart_2.0/blob/master/abantecart/abc/phpunit.xml
Just create yours and start to create test classes.



“No one is useless in this world who lightens the burdens of another.”
― Charles Dickens

 

Powered by SMFPacks Social Login Mod