Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Fix generateShortOrCompleteClassname #75

Merged
merged 4 commits into from
Jun 30, 2016

Conversation

qRoC
Copy link
Contributor

@qRoC qRoC commented Jun 28, 2016

No description provided.

@veewee
Copy link
Contributor

veewee commented Jun 28, 2016

Looks good.
Can you also add a test for this case so that I don't make this mistake again? Thanks!
I hope this one gets patched fast :)

@Ocramius
Copy link
Member

As mentioned by @veewee, a test case is strictly required for fixes to be merged.

@aschwin
Copy link

aschwin commented Jun 28, 2016

Yes! Nice to see it fixed so quick!

@weierophinney
Copy link
Member

@qRoC I really want to get this in, but I really need a test case, for a couple of reasons:

  • I don't know how to reproduce the issue.
  • The project needs to ensure it doesn't break in the future.

Any chance you can get a test in ASAP so I can do a 3.0.4 release, please?

@qRoC
Copy link
Contributor Author

qRoC commented Jun 28, 2016

yes

$classGenerator = new ClassGenerator();
$classGenerator->setName('ClassName');
$classGenerator->setExtendedClass('\DateTime');
$this->assertContains('class ClassName extends DateTime', $classGenerator->generate());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please create new test methods for these two new cases, using a name descriptive of the behavior being tested, and annotate them with @group 75.

Thanks!

weierophinney added a commit that referenced this pull request Jun 30, 2016
Fix generateShortOrCompleteClassname
weierophinney added a commit that referenced this pull request Jun 30, 2016
weierophinney added a commit that referenced this pull request Jun 30, 2016
Close #75
Fixes #74
Fixes #80
Fixes #81
@weierophinney weierophinney merged commit 5eec1af into zendframework:master Jun 30, 2016
basz added a commit to basz/zend-code that referenced this pull request Sep 28, 2016
* 'master' of https://github.com/zendframework/zend-code: (39 commits)
  Fix Travis code convention
  Fix Travis code convention
  Fix Travis code convention
  Fix Travis code convention
  1. Fix ClassScanner::getInterfaces() which don't work with Interface. 2. add TestCase  ClassScannerTest::testGetInterfacesFromInterface().
  Remove fast_finish flag
  Bumped to next dev version (3.0.5)
  Added CHANGELOG for zendframework#75
  Separated new tests to separate methods
  testCorrectExtendNamesFromGlobalNamespace
  add tests
  Added CHANGELOG for zendframework#59
  Update ClassGenerator.php
  fast fix
  Bumped to next dev version (3.0.4)
  Set date for 3.0.3
  Added CHANGELOG for zendframework#72
  Added CHANGELOG for zendframework#69
  Added CHANGELOG for zendframework#61
  Provide a fix for issue zendframework#70
  ...
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants