Skip to content

[Slim] General enhancement discussion #384

@ybelenko

Description

@ybelenko
Description

Hey, PHP guys! 🤝
I'm going to upgrade PhpSlimCodegen to meet community and my personal requirements.
I'm not familiar with spec 3.0, so all text below related to 2.0 version.

  1. Automated UnitTests generation for every model and every endpoint(checks at least response status code and response data types)
  2. Mock API server generation (example properties from responses will be used as mock data). It should covers autogenerated UnitTests automatically, I think.

Few updates that I would do later:

PHP Technical Committee

cc @jebentier @dkarlovi @mandrean @jfastnacht @ackintosh

Questions to PHP Committee

I will try to create basic template which any developer can modify by edit mustache markdown, but we need to decide how advanced it should be by default:

  1. What PHP version should we target? Is it too soon to use type annotation with PHP7 and modern syntax shortcuts? ( [] instead of array(), $_GET['user'] ?? 'nobody' instead of isset($_GET['user']) ? $_GET['user'] : 'nobody')
  2. What PHPUnit version should we target?
  3. Should we use Faker library for mock data or it's too much?
  4. I would like to use .ENV config file with phpdotenv library. I've met a problem Partial loading of .env file on production server vlucas/phpdotenv#266 few times, but I don't see any decent alternatives beside builtin parse_ini_file function with external .INI file as a config.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions