2017-25 © Pedro Peláez
 

library phpspec-sort-use-statements

PhpSpec extension for sorting use statements in generated files.

image

unfunco/phpspec-sort-use-statements

PhpSpec extension for sorting use statements in generated files.

  • Friday, July 20, 2018
  • by honest
  • Repository
  • 0 Watchers
  • 1 Stars
  • 487 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

Sorted use statements for PhpSpec

  1. Are you working on a project with a namespace beginning with Q, R, S, T, U, V, W, X, Y, or Z?
  2. Do you like your use statements sorted alphabetically?

If you answered yes to both of those questions, this is the PhpSpec extension for you!, (*1)

Requirements

Installation and beyond

Using Composer, require this package as a development dependency:, (*2)

$ composer require --dev unfunco/phpspec-sort-use-statements

…and enable the extension by adding the following to your phpspec.yml configuration., (*3)

extensions:
  Unfunco\PhpSpec\Extension\SortUseStatements: ~

Generate specifications as you normally would. If you are using a custom specification template, you can add %use% to your template to interpolate sorted use statements, as in this example:, (*4)

<?php

namespace %namespace%;

%use%

final class %name% extends ObjectBehavior
{
    function it_is_initializable()
    {
        $this->shouldHaveType(%subject_class%::class);
    }
}

License

Copyright © 2018 Daniel Morris
Made available under the terms of the Apache License, Version 2.0., (*5)

The Versions

20/07 2018

dev-master

9999999-dev

PhpSpec extension for sorting use statements in generated files.

  Sources   Download

Apache-2.0

The Requires

 

bdd tdd phpspec

20/07 2018

0.1.1

0.1.1.0

PhpSpec extension for sorting use statements in generated files.

  Sources   Download

Apache-2.0

The Requires

 

bdd tdd phpspec

20/07 2018

0.1.0

0.1.0.0

PhpSpec extension for sorting use statements in generated files.

  Sources   Download

Apache-2.0

The Requires

 

bdd tdd phpspec