Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3393636
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T04:04:28+00:00 2026-05-18T04:04:28+00:00

I’m looking for a simpler test framework. I had a look at a few

  • 0

I’m looking for a simpler test framework. I had a look at a few PHPUnit and SimpleTest scripts and I find the required syntactic sugar appalling. SnapTest sounded nice, but was as cumbersome. Apache More::Test was too procedural, even for my taste. And Symfony lime-test was ununique in that regard.
BDD tools like http://everzet.com/Behat/#basics are very nice, but even two abstraction levels higher than desired.

Moreover I’ve been using throwaway test scripts till now. And I’m wondering if instead of throwing them away, there is a testing framework/tool which simplifies using them for automated tests. Specifically I’d like to use something that:

  • evaluates output (print/echo), or even return values/objects
  • serializes and saves it away as probe/comparison data
  • allows to classify that comparison output as passed test or failure
  • also collects headers, warning or error messages (which might also be expected output)
  • in addition to a few $test->assert() or test::fail() states

Basically I’m too lazy to do the test frameworks work, manually pre-define or boolean evaluate and classify the expected output. Also I don’t find it entertaining to needlessly wrap test methods into classes, plain include scripts or functions should suffice. Furthermore it shouldn’t be difficult to autorun through the test scripts with a pre-initialized base and test environment.

The old .phpt scripts with their –expect– output come close, but still require too much manual setup. Also I’d prefer a web GUI to run the tests. Is there a modern rehersal of such test scripts? (plus some header/error/result evalation and eventually unit test::assert methods)


Edit, I’ll have to give an example. This is your typical PHPUnit test:

 class Test_Something extends PHPUnit_Test_Case_Or_Whatever {
     function tearUp() {
         app::__construct(...);
     }
     function testMyFunctionForProperResults() {
         $this->assertFalse(my_func(false));
         $this->assertMatch(my_func("xyzABC"), "/Z.+c/");
         $this->assertTrue(my_func(123) == 321);
     }
 }

Instead I’d like to use plain PHP with less intermingled test API:

 function test_my_function_for_proper_results() {
     assert::false(my_func(false));
     print my_func("xyz_ABC");
     return my_func(123);
 }

Well, that’s actually three tests wrapped in one. But just to highlight: the first version needs manual testing. What I want is sending/returning the test data to the test framework. It’s the task of the framework to compare results, and not just spoon-feeded booleans. Or imagine I get a bloated array result or object chain, which I don’t want to manually list in the test scripts.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T04:04:29+00:00Added an answer on May 18, 2026 at 4:04 am

    For the record, I’ve now discovered Shinpuru.
    http://arkanis.de/projects/shinpuru/
    Which looks promising for real world test cases, and uses PHP5.3-style anonymous functions instead of introspection-class wrappers.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm looking for suggestions for debugging... If you view this site in Firefox or
I have a jquery bug and I've been looking for hours now, I can't
link Im having trouble converting the html entites into html characters, (&# 8217;) i
Seemingly simple, but I cannot find anything relevant on the web. What is the
Does anyone know how can I replace this 2 symbol below from the string
this is what i have right now Drawing an RSS feed into the php,
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
I want to count how many characters a certain string has in PHP, but

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.