Permalink
Browse files

Mock of model and view.

  • Loading branch information...
1 parent 6f4c03c commit 408ee1e516bf9ddab270fd4a31914659ef6c4578 josterholt committed Dec 6, 2011
View
@@ -4,3 +4,4 @@
/.buildpath
/.project
.~*
+/nbproject/private/
@@ -0,0 +1,5 @@
+{block name="share"}{component shareWidget}{/block}
+{block name="top"}{/block}
+{block name="leftModuleListing"}{component moduleList id="left"}{/block}
+<article>{block name="body"}{/block}</article>
+{block name="comments"}{/block}
@@ -0,0 +1,17 @@
+<h2><a href="{$section.url}">{$section.displayTitle}</a> {component shareWidget}</h2>
+<a href="">{$content.displayTitle}</a>
+<h3>{$content.subTitle}</h3>
+<h4>{$content.title}</h4>
+<byline>{component byline} | {$content.publishDate}</byline>
+{compontent embeddedGallery}
+<div id="ArticleOptions">
+ <thumbnail>
+ {media width=150}
+ <br clear="all" />
+ <byline>Photo by {$content.mainImage.author}</byline>
+ </thumbnail>
+ <br />
+ {component voteWidget}
+</div>
+<article>{$content.body}</article>
+<!-- {component commentBlock} -->
@@ -0,0 +1,21 @@
+<div id="Shareicons">
+ <script language="javascript1.2">var trkcid=134690733;var partnerID=621532; var _hb=1;</script><script src="http://www.governing.com/g/g/button/button_1.js" language="javascript1.2"></script><script language="JavaScript">
+window.onerror=function(){clickURL=document.location.href;return true;}
+if(!self.clickURL) clickURL=parent.location.href;
+</script>
+
+ <!-- AddThis Button BEGIN -->
+ <div class="addthis_toolbox addthis_default_style">
+ <a class="addthis_button_email at300b" title="Email" href="#"><span class="at300bs at15nc at15t_email"></span></a>
+ <a onmouseout="return(PTMouseOut());" onmouseover="return(PTMouseOver());" onclick="window.open(&quot;/templates/gov_print_article?id=134690733&quot;, &quot;print&quot;,&quot;width=600,height=600,scrollbars=1&quot;);" href="#" style="float: left;"><img title="Print" src="http://media.governing.com/designimages/gov_ico_print.gif"></a>
+ <a class="addthis_button_facebook at300b" title="Send to Facebook" href="#"><span class="at300bs at15nc at15t_facebook"></span></a>
+ <a class="addthis_button_twitter at300b" title="Tweet This" href="#"><span class="at300bs at15nc at15t_twitter"></span></a>
+ <a class="addthis_button_delicious at300b" href="http://www.addthis.com/bookmark.php?v=250&amp;winname=addthis&amp;pub=governing&amp;source=tbx-250&amp;lng=en-US&amp;s=delicious&amp;url=http%3A%2F%2Fwww.governing.com%2Ftopics%2Feconomic-dev%2Fwhen-team-leaves-its-stadium-what-do-you-do.html&amp;title=When%20Teams%20Leave%2C%20What%20Do%20You%20Do%20With%20the%20Stadium%3F&amp;ate=AT-governing/-/-/4edd3e821a214364/1&amp;frommenu=1&amp;uid=4edd3e82ecaf22ed&amp;ct=1&amp;pre=http%3A%2F%2Fwww.governing.com%2Fphotos%2F%3Fid%3D134620703&amp;tt=0" target="_blank" title="Send to Delicious"><span class="at300bs at15nc at15t_delicious"></span></a>
+ <a class="addthis_button_google at300b" href="http://www.addthis.com/bookmark.php?v=250&amp;winname=addthis&amp;pub=governing&amp;source=tbx-250&amp;lng=en-US&amp;s=google&amp;url=http%3A%2F%2Fwww.governing.com%2Ftopics%2Feconomic-dev%2Fwhen-team-leaves-its-stadium-what-do-you-do.html&amp;title=When%20Teams%20Leave%2C%20What%20Do%20You%20Do%20With%20the%20Stadium%3F&amp;ate=AT-governing/-/-/4edd3e821a214364/2&amp;frommenu=1&amp;uid=4edd3e82ff420488&amp;ct=1&amp;pre=http%3A%2F%2Fwww.governing.com%2Fphotos%2F%3Fid%3D134620703&amp;tt=0" target="_blank" title="Send to Google"><span class="at300bs at15nc at15t_google"></span></a>
+ <a class="addthis_button_linkedin at300b" href="http://www.addthis.com/bookmark.php?v=250&amp;winname=addthis&amp;pub=governing&amp;source=tbx-250&amp;lng=en-US&amp;s=linkedin&amp;url=http%3A%2F%2Fwww.governing.com%2Ftopics%2Feconomic-dev%2Fwhen-team-leaves-its-stadium-what-do-you-do.html&amp;title=When%20Teams%20Leave%2C%20What%20Do%20You%20Do%20With%20the%20Stadium%3F&amp;ate=AT-governing/-/-/4edd3e821a214364/3&amp;frommenu=1&amp;uid=4edd3e821b4d95a4&amp;ct=1&amp;pre=http%3A%2F%2Fwww.governing.com%2Fphotos%2F%3Fid%3D134620703&amp;tt=0" target="_blank" title="Send to Linkedin"><span class="at300bs at15nc at15t_linkedin"></span></a>
+ <span class="addthis_separator">|</span>
+ <a class="addthis_button_expanded at300m" href="http://addthis.com/bookmark.php?v=250&amp;username=governing" title="View more services"><span class="at300bs at15nc at15t_expanded"></span>More</a>
+ <div class="atclear"></div></div>
+ <script src="http://s7.addthis.com/js/250/addthis_widget.js#username=governing" type="text/javascript"></script>
+ <!-- AddThis Button END -->
+</div>
@@ -0,0 +1,18 @@
+<div style="display: block;" class="left bottom" id="Rating">
+ <form onsubmit="return processRating(this);">
+ <input type="hidden" value="true" name="enableRating">
+ <input type="hidden" value="1" name="rating">
+ <input type="hidden" value="true" name="upvote">
+ <input type="submit" class="ratingbutton1" value=" ">
+ </form>
+ <form onsubmit="return processRating(this);">
+ <input type="hidden" value="true" name="enableRating">
+ <input type="hidden" value="1" name="rating">
+ <input type="hidden" value="true" name="downvote">
+ <input type="submit" class="ratingbutton2" value=" ">
+ </form>
+
+ <br clear="all">
+ <strong id="rank" class="color2 marginright"> 0</strong>
+ <span id="vote_count" class="small"> 0 votes</span>
+</div>
@@ -1,16 +0,0 @@
-{foreach from=$list item=item}
-<li>
- <thumbnail>
- <image>{if $item.mainImage}{image src=$item.mainImage width=150}{/if}</image>
- <br clear="all" />
- <byline>Photo by {$item.mainImage.author}</byline>
- </thumbnail>
- <h4>{$item.title}</h4>
- <p>
- {$item.publishDate}
- {byline src=$item}
- </p>
- <div>{$item.body}</div>
- {socialMedia}
-</li>
-{/foreach}
@@ -0,0 +1,16 @@
+file.reference.php-PHPUnit=../../../usr/share/php/PHPUnit
+include.path=\
+ ${php.global.include.path}:\
+ ${file.reference.php-PHPUnit}
+php.version=PHP_5
+phpunit.bootstrap=test/bootstrap.php
+phpunit.bootstrap.create.tests=true
+phpunit.configuration=test/configuration.xml
+phpunit.run.test.files=true
+phpunit.suite=
+source.encoding=UTF-8
+src.dir=.
+tags.asp=false
+tags.short=true
+test.src.dir=test
+web.root=.
View
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://www.netbeans.org/ns/project/1">
+ <type>org.netbeans.modules.php.project</type>
+ <configuration>
+ <data xmlns="http://www.netbeans.org/ns/php-project/1">
+ <name>docu-zend</name>
+ </data>
+ </configuration>
+</project>
@@ -0,0 +1,30 @@
+<?php
+
+class IndexControllerTest extends Zend_Test_PHPUnit_ControllerTestCase
+{
+
+ public function setUp()
+ {
+ $this->bootstrap = new Zend_Application(APPLICATION_ENV, APPLICATION_PATH . '/configs/application.ini');
+ parent::setUp();
+ }
+
+ public function testIndexAction()
+ {
+ $params = array('action' => 'index', 'controller' => 'Index', 'module' => 'default');
+ $urlParams = $this->urlizeOptions($params);
+ $url = $this->url($urlParams);
+ $this->dispatch($url);
+
+ // assertions
+ $this->assertModule($urlParams['module']);
+ $this->assertController($urlParams['controller']);
+ $this->assertAction($urlParams['action']);
+ $this->assertQueryContentContains("div#welcome h3", "This is your project's main page");
+ }
+
+
+}
+
+
+
@@ -0,0 +1,34 @@
+<?php
+
+require_once dirname(__FILE__) . '/../../../application/models/Article.php';
+
+/**
+ * Test class for Article.
+ * Generated by PHPUnit on 2011-12-01 at 10:17:22.
+ */
+class ArticleTest extends PHPUnit_Framework_TestCase {
+
+ /**
+ * @var Article
+ */
+ protected $object;
+
+ /**
+ * Sets up the fixture, for example, opens a network connection.
+ * This method is called before a test is executed.
+ */
+ protected function setUp() {
+ $this->object = new Article;
+ }
+
+ /**
+ * Tears down the fixture, for example, closes a network connection.
+ * This method is called after a test is executed.
+ */
+ protected function tearDown() {
+
+ }
+
+}
+
+?>
Oops, something went wrong.

0 comments on commit 408ee1e

Please sign in to comment.