Your SlideShare is downloading. ×
Developing For Ubraa
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Developing For Ubraa

398

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
398
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Developing for Ubraa Garrizaldy Santos November 10 2007
  • 2. Who Am I Garrizaldy Santos
      • Software Developer
      • PHP'ing since 4.10
      • Developer for Wingcast Inc.
      • Open Source Contributor
  • 3. Outline
    • Bootstrapping Ubraa  
      • Test-Driven Development
        • We'll do something called Test-Driven Learning and introduce you to PHPUnit, the xUnit testing framework for PHP, while we discuss
          • Object Oriented Programming
          • Good Design
          • Refactoring
  • 4. Outline
      • Coding Standard
      • Documentation
      • Version Control
      • Deployment Practices
      • More Testing!
      • Q&A, Interactive Session
  • 5. Ubraa Introduction: Bootstrapping Ubraa
    • Ubraa needs an Application class. In which our bootstrap file index.php will be using.
      • The class should initialize and sets resources that are needed.
      • The class should run the application.
  • 6. Ubraa Introduction: Requirements
      • Write a class named Ubraa_Application that has two methods.
        • initialize() is called if the class is instantiated.
        • run() is called at the very end of the bootstrap file and send the response.
  • 7. Ubraa Introduction: Design
      • A bootstrapper has to take care of the consistent needs of every page of a web application.
        • Receives all dynamic requests for an application
        • Applies a template for application behavior that we can later extend.
        • It will allow us to later customize the functionality for each unique application.
  • 8. Ubraa The First Test
    • <?php require_once 'Ubraa_Application.php' ; class testUbraa_Application extends PHPUnit_Framework_TestCase { }
  • 9. Ubraa The First Test
    • <?php require_once 'Ubraa_Application.php'; class testUbraa_Application extends PHPUnit_Framework_TestCase {     public function testApplication()     {         $app = new Ubraa_Application(); }
  • 10. Ubraa The First Test
    • <?php class Ubraa_Application { }
  • 11. Ubraa The First Test
    • <?php require_once 'Ubraa_Application.php'; class testUbraa_Application extends PHPUnit_Framework_TestCase {     public function testApplication()     {         $app = new Ubraa_Application();         $this ->assertType( 'Ubraa_Application' , $app ); }
  • 12. Ubraa The First Test
    • garrizaldy@desktop:/var/www/ubraa/tests/Ubraa$ phpunit  Ubraa_AllTests AllTests.php PHPUnit 3.1.9 by Sebastian Bergmann. . Time: 0 seconds OK (1 test) garrizaldy@desktop:/var/www/ubraa/tests/Ubraa$
  • 13. Ubraa Related Links
      • Zend Framework - http://framework.zend.com/
      • PHPUnit - http://www.phpunit.de/
      • SimpleTest - http://simpletest.org/
      • Automatic testing of MVC applications created with Zend Framework | Alex @ Net
    • More TDD:
      • Zend_Application
  • 14. Thank you! Garrizaldy Santos [email_address]

×