<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Asridha2</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Asridha2"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Asridha2"/>
	<updated>2026-07-01T07:41:01Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68758</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68758"/>
		<updated>2012-10-27T01:25:55Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Introduction */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
Testing plays a major role in the software development cycle. It is a well known fact that mandatory testing of every functionality implemented be done so as to ensure that the code does not break when in production. Testing can be done in four main stages: Unit testing (individual code modules are tested for flaws and re-coded if any errors are found), Integration testing (various interacting modules are put together piece by piece to ensure that seamless integration exists among them), System testing (the system is tested as a whole after it has been fully integrated) and Acceptance testing (potential users test the system for flaws in design or execution and to see if the product matches their expectation).&lt;br /&gt;
&lt;br /&gt;
This article focuses on Unit testing by following the Test Driven Development approach for Ruby using RSpec framework.&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*'''Fast''':&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*'''Independent''': &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*'''Repeatable''': &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*'''Self-checking''': &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*'''Timely''': &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
[http://en.wikipedia.org/wiki/Domain-specific_language Domain Specific Languages] (DSLs) are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), [http://en.wikipedia.org/wiki/Regular_expression Regexes], [http://en.wikipedia.org/wiki/SQL SQL].&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[http://en.wikipedia.org/wiki/RSpec RSpec] is a testing tool for [http://en.wikipedia.org/wiki/Ruby_%28programming_language%29 Ruby] [http://rspec.info/]. It is based on [http://en.wikipedia.org/wiki/Behavior-driven_development Behavior Driven Development(BDD)] framework and is inspired by [http://jbehave.org/ JBehave] which is another BDD testing framework [http://en.wikipedia.org/wiki/RSpec]. RSpec is considered a DSL for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host [http://en.wikipedia.org/wiki/Domain-specific_language].&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a            [http://guides.rubyonrails.org/command_line.html Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [http://en.wikipedia.org/wiki/Cucumber_%28software%29 Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper is a file that RSpec creates as a part of the install step [http://jeffkreeftmeijer.com/2011/spec-helpers-bundler-setup-faster-rails-test-suites/]. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
&lt;br /&gt;
=Summary=&lt;br /&gt;
A good test case must adhere to the FIRST principle (Fast, Independent, Repeatable, Self-checking, Timely). TDD or Test Driven Development is the approach in which test cases are written for code even before the implementation is realized. DSLs or Domain Specific Languages take on a very specialized set of tasks. When unit tests are written using RSpec, which is an embedded DSL for Ruby testing, we usually write the tests for the controller and model methods and leave the view testing to Cucumber. The Spec files are stored in the Spec directory which mimics the application directory structure. RSpec can be used to perform unit and functional testing.&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Other Interesting Links=&lt;br /&gt;
*[http://net.tutsplus.com/tutorials/php/the-newbies-guide-to-test-driven-development/ Newbies guide to TDD]&lt;br /&gt;
*[http://www.codeproject.com/Articles/9099/The-30-Minute-Regex-Tutorial The 30 minute Regex tutorial]&lt;br /&gt;
*[http://www.andrejkoelewijn.com/wp/2008/10/27/sql-is-a-dsl/ SQL is a DSL]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68727</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68727"/>
		<updated>2012-10-27T01:18:08Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Other Interesting Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*'''Fast''':&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*'''Independent''': &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*'''Repeatable''': &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*'''Self-checking''': &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*'''Timely''': &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
[http://en.wikipedia.org/wiki/Domain-specific_language Domain Specific Languages] (DSLs) are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), [http://en.wikipedia.org/wiki/Regular_expression Regexes], [http://en.wikipedia.org/wiki/SQL SQL].&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[http://en.wikipedia.org/wiki/RSpec RSpec] is a testing tool for [http://en.wikipedia.org/wiki/Ruby_%28programming_language%29 Ruby][http://rspec.info/]. It is based on [http://en.wikipedia.org/wiki/Behavior-driven_development Behavior Driven Development(BDD)] framework and is inspired by [http://jbehave.org/ JBehave] which is another BDD testing framework [2]. RSpec is considered a DSL for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[3]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a               [http://guides.rubyonrails.org/command_line.html Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [http://en.wikipedia.org/wiki/Cucumber_%28software%29 Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper is a file that RSpec creates as a part of the install step[4]. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
&lt;br /&gt;
=Summary=&lt;br /&gt;
A good test case must adhere to the FIRST principle (Fast, Independent, Repeatable, Self-checking, Timely). TDD or Test Driven Development is the approach in which test cases are written for code even before the implementation is realized. DSLs or Domain Specific Languages take on a very specialized set of tasks. When unit tests are written using RSpec, which is an embedded DSL for Ruby testing, we usually write the tests for the controller and model methods and leave the view testing to Cucumber. The Spec files are stored in the Spec directory which mimics the application directory structure. RSpec can be used to perform unit and functional testing.&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Other Interesting Links=&lt;br /&gt;
*[http://net.tutsplus.com/tutorials/php/the-newbies-guide-to-test-driven-development/ Newbies guide to TDD]&lt;br /&gt;
*[http://www.codeproject.com/Articles/9099/The-30-Minute-Regex-Tutorial The 30 minute Regex tutorial]&lt;br /&gt;
*[http://www.andrejkoelewijn.com/wp/2008/10/27/sql-is-a-dsl/ SQL is a DSL]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68722</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68722"/>
		<updated>2012-10-27T01:16:21Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Also see */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*'''Fast''':&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*'''Independent''': &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*'''Repeatable''': &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*'''Self-checking''': &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*'''Timely''': &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
[http://en.wikipedia.org/wiki/Domain-specific_language Domain Specific Languages] (DSLs) are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), [http://en.wikipedia.org/wiki/Regular_expression Regexes], [http://en.wikipedia.org/wiki/SQL SQL].&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[http://en.wikipedia.org/wiki/RSpec RSpec] is a testing tool for [http://en.wikipedia.org/wiki/Ruby_%28programming_language%29 Ruby][http://rspec.info/]. It is based on [http://en.wikipedia.org/wiki/Behavior-driven_development Behavior Driven Development(BDD)] framework and is inspired by [http://jbehave.org/ JBehave] which is another BDD testing framework [2]. RSpec is considered a DSL for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[3]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a               [http://guides.rubyonrails.org/command_line.html Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [http://en.wikipedia.org/wiki/Cucumber_%28software%29 Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper is a file that RSpec creates as a part of the install step[4]. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
&lt;br /&gt;
=Summary=&lt;br /&gt;
A good test case must adhere to the FIRST principle (Fast, Independent, Repeatable, Self-checking, Timely). TDD or Test Driven Development is the approach in which test cases are written for code even before the implementation is realized. DSLs or Domain Specific Languages take on a very specialized set of tasks. When unit tests are written using RSpec, which is an embedded DSL for Ruby testing, we usually write the tests for the controller and model methods and leave the view testing to Cucumber. The Spec files are stored in the Spec directory which mimics the application directory structure. RSpec can be used to perform unit and functional testing.&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;br /&gt;
[[http://net.tutsplus.com/tutorials/php/the-newbies-guide-to-test-driven-development/ Newbies guide to TDD]]&lt;br /&gt;
[[http://www.codeproject.com/Articles/9099/The-30-Minute-Regex-Tutorial The 30 minute Regex tutorial]]&lt;br /&gt;
[[http://www.andrejkoelewijn.com/wp/2008/10/27/sql-is-a-dsl/ SQL is a DSL]]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68718</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68718"/>
		<updated>2012-10-27T01:15:50Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Also see */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*'''Fast''':&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*'''Independent''': &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*'''Repeatable''': &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*'''Self-checking''': &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*'''Timely''': &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
[http://en.wikipedia.org/wiki/Domain-specific_language Domain Specific Languages] (DSLs) are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), [http://en.wikipedia.org/wiki/Regular_expression Regexes], [http://en.wikipedia.org/wiki/SQL SQL].&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[http://en.wikipedia.org/wiki/RSpec RSpec] is a testing tool for [http://en.wikipedia.org/wiki/Ruby_%28programming_language%29 Ruby][1]. It is based on [http://en.wikipedia.org/wiki/Behavior-driven_development Behavior Driven Development(BDD)] framework and is inspired by [http://jbehave.org/ JBehave] which is another BDD testing framework [2]. RSpec is considered a DSL for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[3]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a               [http://guides.rubyonrails.org/command_line.html Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [http://en.wikipedia.org/wiki/Cucumber_%28software%29 Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper is a file that RSpec creates as a part of the install step[4]. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
&lt;br /&gt;
=Summary=&lt;br /&gt;
A good test case must adhere to the FIRST principle (Fast, Independent, Repeatable, Self-checking, Timely). TDD or Test Driven Development is the approach in which test cases are written for code even before the implementation is realized. DSLs or Domain Specific Languages take on a very specialized set of tasks. When unit tests are written using RSpec, which is an embedded DSL for Ruby testing, we usually write the tests for the controller and model methods and leave the view testing to Cucumber. The Spec files are stored in the Spec directory which mimics the application directory structure. RSpec can be used to perform unit and functional testing.&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;br /&gt;
[http://net.tutsplus.com/tutorials/php/the-newbies-guide-to-test-driven-development/ Newbies guide to TDD]&lt;br /&gt;
[http://www.codeproject.com/Articles/9099/The-30-Minute-Regex-Tutorial The 30 minute Regex tutorial]&lt;br /&gt;
[http://www.andrejkoelewijn.com/wp/2008/10/27/sql-is-a-dsl/ SQL is a DSL]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68707</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68707"/>
		<updated>2012-10-27T01:10:05Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Summary */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*'''Fast''':&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*'''Independent''': &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*'''Repeatable''': &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*'''Self-checking''': &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*'''Timely''': &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
[http://en.wikipedia.org/wiki/Domain-specific_language Domain Specific Languages] (DSLs) are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), [http://en.wikipedia.org/wiki/Regular_expression Regexes], [http://en.wikipedia.org/wiki/SQL SQL].&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[http://en.wikipedia.org/wiki/RSpec RSpec] is a testing tool for [http://en.wikipedia.org/wiki/Ruby_%28programming_language%29 Ruby][1]. It is based on [http://en.wikipedia.org/wiki/Behavior-driven_development Behavior Driven Development(BDD)] framework and is inspired by [http://jbehave.org/JBehave] which is another BDD testing framework [2]. RSpec is considered a DSL for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[3]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper[] is a file that RSpec creates as a part of the install step. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
=Summary=&lt;br /&gt;
A good test case must adhere to the FIRST principle (Fast, Independent, Repeatable, Self-checking, Timely). TDD or Test Driven Development is the approach in which test cases are written for code even before the implementation is realized. DSLs or Domain Specific Languages take on a very specialized set of tasks. When unit tests are written using RSpec, which is an embedded DSL for Ruby testing, we usually write the tests for the controller and model methods and leave the view testing to Cucumber. The Spec files are stored in the Spec directory which mimics the application directory structure. RSpec can be used to perform unit and functional testing.&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68702</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68702"/>
		<updated>2012-10-27T01:08:00Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper[] is a file that RSpec creates as a part of the install step. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
=Summary=&lt;br /&gt;
A good test case must adhere to the FIRST principle (Fast, Independent, Repeatable, Self-checking, Timely). TDD or Test Driven Development is the approach in which test cases are written for code even before the implementation is realized. DSLs or Domain Specific Languages take on a very specialized set of tasks. When unit tests are written using RSpec, which is an embedded DSL for Ruby testing, we usually write the tests for the controller and model methods and leave the view testing to Cucumber. The Spec files are stored in the Spec directory which mimics the application directory structure. The spec_helper file which facilitates testing, is installed with RSpec. &lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68677</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68677"/>
		<updated>2012-10-27T00:53:48Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper[] is a file that RSpec creates as a part of the install step. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
In the code, ''it'' is a method that takes in a string parameter. This string describes the actions to be performed that corresponds to the specification given in the user story. Further behaviors can be added to or nested within the main describe block, or new test scripts can be written, as per requirements.&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68670</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68670"/>
		<updated>2012-10-27T00:50:50Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
User stories are taken as the input to write RSpecs. The following is an example of one such user story:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
When I fill in &amp;quot;Search Posts&amp;quot; with &amp;quot;Assignments&amp;quot;&lt;br /&gt;
And I press &amp;quot;Search&amp;quot;&lt;br /&gt;
Then I should be on the Posts page with Assignment Posts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once we have the user stories ready, the next is to implement the corresponding code to realize this test case.&lt;br /&gt;
==The code we wish we had==&lt;br /&gt;
When the user clicks on the button in the view for search_posts, the controller action receives the form submission and should perform the following actions:&lt;br /&gt;
#It will call a method that searches the BackChannel App for posts with the specified search term(s)&lt;br /&gt;
#It then calls the model method to check the database to see if the entered value exists. &lt;br /&gt;
#If there is a match, a view with the Posts corresponding to the search terms is rendered. If no match is found, there should be a redirection to the homepage with an error message for the user's information.&lt;br /&gt;
The RSpec for the above mentioned scenario can be written as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require 'spec_helper'&lt;br /&gt;
describe PostController do&lt;br /&gt;
  describe 'searching Posts' do&lt;br /&gt;
    it 'should call the model method that performs Post search'&lt;br /&gt;
    it 'should select the Search Results template for rendering'&lt;br /&gt;
    it 'should make the Post search results available to that template'&lt;br /&gt;
  end&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Spec_helper[] is a file that RSpec creates as a part of the install step. This file ensures that the functions required for  testing are loaded. The behavior of the post controller is described in the code block. The main behavior that we are focusing on is searching post. &lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68607</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68607"/>
		<updated>2012-10-27T00:24:57Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Features of RSpec */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
== The code you wish you had – Seam – when the user clicks on the button in the view for search_tmdb – controller action receives the form submission – It then calls a model method to check the database to see if the entered value exists.&lt;br /&gt;
Movie found – render view with search results – else homepage with an error or message&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68604</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68604"/>
		<updated>2012-10-27T00:24:00Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Features of RSpec */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The code you wish you had – Seam – when the user clicks on the button in the view for search_tmdb – controller action receives the form submission – It then calls a model method to check the database to see if the entered value exists.&lt;br /&gt;
Movie found – render view with search results – else homepage with an error or message&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68601</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68601"/>
		<updated>2012-10-27T00:23:38Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Features of RSpec */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
}&lt;br /&gt;
The code you wish you had – Seam – when the user clicks on the button in the view for search_tmdb – controller action receives the form submission – It then calls a model method to check the database to see if the entered value exists.&lt;br /&gt;
Movie found – render view with search results – else homepage with an error or message&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68598</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68598"/>
		<updated>2012-10-27T00:22:50Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|Apps folder !! Spec folder&lt;br /&gt;
|-&lt;br /&gt;
| app/models/*.rb || spec/models/*_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
|app/controllers/ *_controller.rb || spec/controllers/ *_controller_spec.rb&lt;br /&gt;
|-&lt;br /&gt;
| app/views/*/*.html.erb || Use Cucumber&lt;br /&gt;
|}&lt;br /&gt;
}&lt;br /&gt;
The code you wish you had – Seam – when the user clicks on the button in the view for search_tmdb – controller action receives the form submission – It then calls a model method to check the database to see if the entered value exists.&lt;br /&gt;
Movie found – render view with search results – else homepage with an error or message&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68581</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68581"/>
		<updated>2012-10-27T00:16:33Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
The code you wish you had – Seam – when the user clicks on the button in the view for search_tmdb – controller action receives the form submission – It then calls a model method to check the database to see if the entered value exists.&lt;br /&gt;
Movie found – render view with search results – else homepage with an error or message&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68578</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68578"/>
		<updated>2012-10-27T00:15:30Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=DSL=&lt;br /&gt;
DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is not general. &lt;br /&gt;
Examples for DSLs include migration scripts (which are a small set of statements with the sole job of expressing changes in the database schema), Regexes, SQL.&lt;br /&gt;
&lt;br /&gt;
=RSpec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. The notable difference between RSpec and SQL is that, while RSpec is an internal DSL, SQL is stand alone. Internal or embedded DSLs are implemented within another language that acts as their host.[]&lt;br /&gt;
==Features of RSpec==&lt;br /&gt;
*Each test in RSpec is called a ''spec'' (which is short for specification).&lt;br /&gt;
*RSpec code inhabits the Spec directory which mimics the directory structure of the application.&lt;br /&gt;
**''rspec:install'' is a [Rails generator] that creates the sub-directory structure for the Spec directory. &lt;br /&gt;
*Specs are usually written for the controller and model methods. View spec checking is done mostly using the controller spec (seeing that the view will call controller method) and so, specs are usually not written for view. Instead, one can use [Cucumber] to test the view functionality.&lt;br /&gt;
The code you wish you had – Seam – when the user clicks on the button in the view for search_tmdb – controller action receives the form submission – It then calls a model method to check the database to see if the entered value exists.&lt;br /&gt;
Movie found – render view with search results – else homepage with an error or message&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68513</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68513"/>
		<updated>2012-10-27T00:01:14Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where [http://en.wikipedia.org/wiki/Software_quality_assurance Quality Assurance] department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the [http://en.wikipedia.org/wiki/Test-driven_development Test Driven Development (TDD)] approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=Rspec=&lt;br /&gt;
[RSpec] is a testing tool for [Ruby][1]. It is based on [Behavior Driven Development(BDD)] framework and is inspired by [JBehave] which is another BDD testing framework[2]. RSpec is considered a [Domain Specific Language(DSL)] for writing tests. DSLs are small programming languages that do only a small number of activities within a specific task domain. Thus we can say that a DSL is specialized.&lt;br /&gt;
*&lt;br /&gt;
DSL for writing test – small programming lang that does only a small number of tasks within a task domain – specialized – Migrations – small set of statements- sole job to express changes in database schema – ruby code stylized to look like the tasks they do – embedded ruby code – Rspec – internal DSL – implemented inside another language – SQL – stand alone DSL&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68452</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68452"/>
		<updated>2012-10-26T23:40:44Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
=Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: &lt;br /&gt;
**The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: &lt;br /&gt;
**Testing field has changed considerably. Where Quality Assurance department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: &lt;br /&gt;
**Testing should follow the Test Driven Development (TDD) approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=Disadvantages of QA=&lt;br /&gt;
&lt;br /&gt;
=Rspec=&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68451</id>
		<title>CSC/ECE 517 Fall 2012/ch2a 2w30 an</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch2a_2w30_an&amp;diff=68451"/>
		<updated>2012-10-26T23:40:03Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;''' SaaS - 5.2 - FIRST, TDD and getting started with RSpec'''&amp;lt;/big&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Introduction=&lt;br /&gt;
&lt;br /&gt;
Characteristics of a good Unit test=&lt;br /&gt;
*Fast:&lt;br /&gt;
**The tests should not take too long to run. Sometimes it would seem more logical to run only a subset of the tests (for example, when a part of the code breaks or only a particular functionality of the code is being developed). In such cases, it would not be productive if the tests take quite a bit of time to finish executing.  &lt;br /&gt;
*Independent: &lt;br /&gt;
**When tests are being run, the order of execution of the tests should not matter. More importantly, tests should not be inter-dependent; which means that, it should be possible to run any subset of the test set in any order. Also, no test should be a prerequisite for another test.&lt;br /&gt;
*Repeatable: The output for a test execution should be consistent irrespective of the number of times that it is run. This is essential in order to isolate bugs and enable automation. If the test notices the presence of a bug on the first run, it should do so on every consecutive run.&lt;br /&gt;
*Self-checking: Testing field has changed considerably. Where Quality Assurance department was involved to check the functionality of the code, it is now all automated. It is therefore, now mandatory that all tests themselves know if it is a pass or fail. No human intervention should be expected. Also, tests can run in the back all the time which means that if there is a change in the code or when the code breaks, the test script should be able to identify the same without human intervention.&lt;br /&gt;
*Timely: Testing should follow the Test Driven Development (TDD) approach. Here, the test cases are written before the code is implemented or at least around the same time (and not after!). Hence, if the functionality of the code being tested changes, the respective test cases should change correspondingly.&lt;br /&gt;
&lt;br /&gt;
=Disadvantages of QA=&lt;br /&gt;
&lt;br /&gt;
=Rspec=&lt;br /&gt;
&lt;br /&gt;
=Conclusion=&lt;br /&gt;
&lt;br /&gt;
=References=&lt;br /&gt;
&lt;br /&gt;
=Also see=&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65517</id>
		<title>CSC/ECE 517 Fall 2012/ch1 1w11 ap</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65517"/>
		<updated>2012-09-22T02:41:52Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Designing Software */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&amp;lt;b&amp;gt; CRC Cards, &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] cards are a brainstorming tool to enable collaboration across different teams or individuals in contribution to design, usually used in Object Oriented Software development. This was  proposed by &amp;lt;b&amp;gt;Ward Cunningham&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;Kent Beck&amp;lt;/b&amp;gt;&amp;lt;sup&amp;gt;[http://c2.com/doc/oopsla89/paper.html]&amp;lt;/sup&amp;gt;. The CRC card can be viewed as an index card, with the following details:&lt;br /&gt;
[[Image:crc-card.gif|frame|right|CRC Card Structure]]&lt;br /&gt;
&lt;br /&gt;
:* The Top of the card usually bears the name of the class.&lt;br /&gt;
:* The Left side of the card has the responsibilities of the class.&lt;br /&gt;
:* The Right side of the card has the collaborating classes corresponding to each of the responsibilities listed in the left side.&lt;br /&gt;
&lt;br /&gt;
Thus in general, a CRC session can be viewed as the interaction between a set of collaborating classes for a particular [http://en.wikipedia.org/wiki/Use_case Use case]. &amp;lt;br&amp;gt; &amp;lt;br&amp;gt; According to &amp;lt;sup&amp;gt;[http://www.extremeprogramming.org/rules/crccards.html]&amp;lt;/sup&amp;gt;&amp;lt;i&amp;gt;A CRC session proceeds with someone simulating the system by talking about which objects send messages to other objects. By stepping through the process' weaknesses and problems are easily uncovered. Design alternatives can be explored quickly by simulating the design being proposed.&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===A CRC Example===&lt;br /&gt;
To better understand how the CRC cards work together, let us consider a simple student enrollment problem,where we are required to model the students enrolled in different courses. We can easily define the &amp;lt;b&amp;gt;Student CRC Card&amp;lt;/b&amp;gt; as having attributes such as student name, student id and responsibilities that enable a student to enroll in a course or drop the course. In this particular instance, the collaborating class would be the &amp;lt;b&amp;gt;Course&amp;lt;/b&amp;gt; class. The &amp;lt;b&amp;gt;Course CRC Card&amp;lt;/b&amp;gt; can in turn be visualized as having its own responsibilities, such as having attributes like Course id, course name and the collaborating class would be the &amp;lt;b&amp;gt;Instructor &lt;br /&gt;
class&amp;lt;/b&amp;gt;. The CRC cards for the Student class and the Course Class are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[Image:Stud_enr_Crc.jpg|frame|center|Student and Course CRC Card]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There are also several practical designs that use the CRC card model to design Object oriented software design. The  [http://www.extremeprogramming.org/example/crcsim.html Simulator for Coffee Maker] explores an [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] approach combined with CRC card technique to come up with a design for the coffee maker.&lt;br /&gt;
&lt;br /&gt;
Another interesting approach using CRC cards is the design for the [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html ATM Machine]&lt;br /&gt;
&lt;br /&gt;
===Advantages of CRC cards===&lt;br /&gt;
There are a few advantages of CRC cards that make it a preferable model in many designs. Some of the advantages of the CRC card design method are&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:* CRC cards can allow designers to easily make audience understand a very complex system. In essence it allows for building more complex designs by slowly building the interactions between the collaborating classes, one by one.&lt;br /&gt;
:* CRC cards are a simple technique and it can be easily used by anyone with very little training and does not require any expensive computing resources(a board or a paper and a pen would suffice).&lt;br /&gt;
:* CRC is fundamentally a brainstorming tool, enabling different people in a team to come up with the design by collaborating, enabling everyone in the team to contribute&lt;br /&gt;
:* CRC can be used with other formal object oriented design methodologies such as [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] (an [http://en.wikipedia.org/wiki/Agile_Modeling Agile] development Technique) and can be used along with modeling languages such as [http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
&lt;br /&gt;
==Software for CRC Cards==&lt;br /&gt;
CRC cards have limited scope. If we go about designing a huge project, the scope may span many classes and there might be numerous interactions between them. The tedious task here is to maintain the CRC cards and formulate appropriate interaction between them. &lt;br /&gt;
We need software for CRC Cards for the following reasons:&lt;br /&gt;
:* &amp;lt;b&amp;gt;Designing Scenario:&amp;lt;/b&amp;gt;  A scenario represents a series of steps in which classes and objects communicate. There can be references to other scenarios. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Modeling :&amp;lt;/b&amp;gt;  Software provides an easy way to segregate cards and objects into different diagrams. Thus we can model our problem with different functionality very easily.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Simulation :&amp;lt;/b&amp;gt; Software can provide simulation of the design. This might include single-stepping a scenario forward or backwards or jumping to a specific location in the scenario stack of a multiple scenario simulation.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Synchronization and Dependencies:&amp;lt;/b&amp;gt; Software can maintain relationships between cards and scenarios as design changes take place. If a card references other cards or classes, any changes in those cards are generated automatically. Also any name changes and cross references between objects are instantly updated. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Revision history and [http://en.wikipedia.org/wiki/Revision_control Version Control] :&amp;lt;/b&amp;gt; Software for CRC cards supports changes to CRC cards. It is easy to model and keep track of all changes to a CRC card. This is extremely helpful in tracking design changes.&lt;br /&gt;
&lt;br /&gt;
==Designing Software==&lt;br /&gt;
The steps to design software for CRC cards are:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Create CRC Cards&amp;lt;/b&amp;gt; : A CRC model is usually created by an individual (or small group of designers) during the early phase of an object-oriented development project. The figure shows the design of hierarchy of classes. The set of class used for drawing objects are shown. We can see TShape class has a superclass called TObject and two subclasses, TBox and TCircle. Let us assume we create new class TWindow derived from the superclass TObject.  [[Image:Design.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Assign Responsibilities&amp;lt;/b&amp;gt; : Once a set of classes are defined, behaviors can be assigned that will provide the functions of the application. For example, the TShape card has responsibilities ''Initialize'' to create it and ''Draw'' to illustrate it on the diagram.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Add Attributes&amp;lt;/b&amp;gt; : Attributes of classes may also be identified in a CRC Card. The TShape class has attributes fPosition, fType and fSelected.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Define and simulate Scenario&amp;lt;/b&amp;gt; : A scenario describes a sequence of steps in the design using the responsibilities of a group of collaborating classes. Collaboration between classes refers to a client object that uses a responsibility performed by a server object. Often a class must call upon several collaborating classes to implement one of its responsibilities. A scenario describes what happens in the system from a high-level, user's point of view.&lt;br /&gt;
[[Image:Scenario.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
Consider the situation to the right. We have defined two CRC cards with their responsibilities. A scenario defines several steps. Each step in a scenario has a Client, Server and Responsibility field. For each step, a client class uses a responsibility of a server class&lt;br /&gt;
&lt;br /&gt;
The Open Document scenario in the picture references the Initialize Document sub-scenario by specifying its server class ''Document'' in the server field and its scenario name in the Responsibility field. The first step in the Initialize Document sub-scenario uses ''Document'' as the server class name. By single-stepping forward, backwards or through each sub-scenario, bugs in the design can be identified and corrected early.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Partition the Design&amp;lt;/b&amp;gt; : As the number of CRC cards in the design grow, they can be grouped by function. By using Software for CRC cards, we can draw separate diagrams to partition the model into different subject areas. &lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;[http://www.google.com/search?q=what+is+an+inheritance+graph&amp;amp;rlz=1C1CHFX_enUS460US460&amp;amp;sugexp=chrome,mod=14&amp;amp;sourceid=chrome&amp;amp;ie=UTF-8#hl=en&amp;amp;rlz=1C1CHFX_enUS460US460&amp;amp;q=inheritance+graph&amp;amp;tbs=dfn:1&amp;amp;tbo=u&amp;amp;sa=X&amp;amp;ei=IyFdUK_wAZLw8ATD8oHgCw&amp;amp;ved=0CB8QkQ4&amp;amp;bav=on.2,or.r_gc.r_pw.r_qf.&amp;amp;fp=99d6414d69e5a888&amp;amp;biw=1517&amp;amp;bih=783 Inheritance Graph]&amp;lt;/b&amp;gt; : An automated tool can generate an inheritance graph from information on CRC cards. This diagram can concisely illustrate the big picture of a large project that might contain hundreds of classes and dozens of diagrams.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Verify Your Work &amp;lt;/b&amp;gt; : Creating and simulating scenarios will help verify that a design is correct and complete. A CRC software can perform other error checks to locate design problems. For example, responsibilities that are not used in any scenarios may indicate that the design is incomplete or perhaps the responsibility isn't needed. Likewise, a card that is not used by any collaboration may not be needed.&lt;br /&gt;
&lt;br /&gt;
==Software Development Process for Object Oriented Development&amp;lt;sup&amp;gt;[6]&amp;lt;/sup&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
Software Development Life Cycles are different for a standard development process and for Object Oriented development. This difference needs to be understood in order to know how to meet the benchmarks set for the project. There are multiple processes that are used in software development, the most common ones in use being Waterfall model and Spiral model. The Waterfall model is progression based and the Spiral model is iterative.&lt;br /&gt;
&lt;br /&gt;
We need to understand that the uniqueness of Object Oriented SDLCs comes from the fact that it is more user centric as compared to standard SDLCs that are more system centric. We will now see which models work for Object Oriented SDLCs (OO SDLCs) and which don’t. CRC cards play a very important role in an Object Oriented SDLC. Thus, figuring out which models work well for OO SDLCs will result in understanding which models use CRC cards and why.&lt;br /&gt;
 &lt;br /&gt;
====The Waterfall Model====&lt;br /&gt;
&lt;br /&gt;
The Waterfall model is implemented in multiple phases with each phase having a clear demarcation in terms of its functionality and deliverable. It uses clear stepping stones to come up with deliverables for each deadline. In this case, there are multiple ways to measure progress and methods by which to audit internally and apply checkpoints.&lt;br /&gt;
&lt;br /&gt;
The downside of the Waterfall model lies in the fact that it is a very rigid model that does not offer much in terms of leeway when it comes to deliverables and what each phase in the cycle has to offer. The process is also overly mechanical and over time, just ends up being boring.&lt;br /&gt;
&lt;br /&gt;
Owing to the emphasis on checkpoints and deliverables with strict deadlines, in most cases the analysis and design phases are usually cut short and thus, the project may veer very far from reality. The users are involved only in the requirement gathering phase. This might result in mistranslation of the requirements of the user into what may be an amazing final product but something that the user did not even ask for.&lt;br /&gt;
 &lt;br /&gt;
====The Spiral Model====&lt;br /&gt;
This model iteratively goes through the phases of analysis, design, prototyping and testing after the initial requirements gathering phase. With each iteration, the product is improved based on the feedback from testing in the previous iteration. If required, the outcome of each phase is analyzed, revised and the next prototype is developed after the design is revised, if pertinent. The products from the first phase are not abandoned, they are revised. Evidently, this model is non-linear in nature.&lt;br /&gt;
&lt;br /&gt;
After the first pass through the checkpoint, we can conclude that the work so far is adequate, but not final. The model places emphasis on the iterative process and on the development of standard prototypes at the end of each iteration. At the end of every cycle, we notice the shortcomings from the previous cycle and might end up having to redo all the work in the previous cycle. This proves to be a complete waste of time and effort. All the effort now goes into developing the end point for an older cycle, which makes the model ineffective for the current cycle.&lt;br /&gt;
&lt;br /&gt;
One of the major drawbacks of such a non linear model is that the cost effectiveness and risk analysis cannot be analyzed thoroughly.&lt;br /&gt;
 &lt;br /&gt;
====Why CRC cards are not useful in Waterfall and Spiral Models====&lt;br /&gt;
&lt;br /&gt;
The strength of OO model depends on the idea that, here, design and deployment come together. In the case of a spiral model, this works to make the spiral tighter. Since the waterfall model places over importance on deliverables and user involvement is minimal, which is one of the key focuses of OO SLDCs using CRC cards, the model is considered ineffective. The Spiral model involves multiple revisions of the same idea. When a set of cards have been developed, it would make sense to refine the idea presented in the card but not to redefine them over and over, which may be the case. This does not serve the purpose of actually convening a CRC discussion among the team to draw up cards corresponding to the user requirement. Moreover, in the case of the Spiral model, we would need to convene multiple such meetings at each iteration, which would drastically bring down the overall productivity of the team.&lt;br /&gt;
&lt;br /&gt;
==CRC Cards in Software Development Process==&lt;br /&gt;
&lt;br /&gt;
===Agile Methodology and CRC Cards===&lt;br /&gt;
&lt;br /&gt;
Agile development is a model that has resurfaced and is gaining fame for its incremental cum iterative process. The iteration is carried over the processes of discovery, analysis, design and coding. In each iteration, the old model is worked on in each of the overlapping mini-cycles. The overlap of the cycles makes the process apparently iterative in nature. The model is considered incremental since every step acts as a value-add and this is emphasized by the capacity of classes for reuse. The idea that each phase is repeated ensures that the project is constantly working on a higher level of understanding. Moreover, the OOPS concept of reuse can be used to our advantage such that when we are continuously using OO development models in all our projects, the next implementation can be started  far ahead in the SDLC.&lt;br /&gt;
&lt;br /&gt;
The model focuses on analysis and design phase predominantly. Within each of these are mini phases of analysis-&amp;gt;prototype-&amp;gt;revision-&amp;gt; implementation cycles. The advantage of this model compared to other models described is that, being incremental, this also results in tightening of the spiral at the end of each iteration using concepts such as reusability and polymorphism. Thus, the progression from one point to another in the cycle is seamless from start to deployment.&lt;br /&gt;
&lt;br /&gt;
CRC cards can be very effectively and efficiently used in the Agile model of OO SDLC owing to the fact that it is incremental as well as iterative and not just a repetitive process. Thus, we would not have to redefine the cards from the scratch at any point. Being incremental, we would refine our current model and proceed to refine the entire system as a whole at the end of all iterations. We would essentially be adding value to the cards written out in the previous cycle and if perfected, would never have to discard cards from any of the precious cycles.&lt;br /&gt;
            &lt;br /&gt;
Agile also practices active customer involvement. In every phase, the user is involved. This is one of the key characteristics of the CRC card design method. This not only ensures that the final product is as per the customer's requirements, but also that the customer is thoroughly satisfied, since they are aware of the changes and increments at each level. Another key aspect of Agile methodology is that it is feature driven. A CRC card holds details as to the feature of each class and how it collaborates with the rest of the system. Since this information is readily available to the developer and is highly fine-tuned by the end of the SDLC process, the cards can guarantee focus on 80/20 principle (i.e. pay more attention to 20% of the features which will used 80% of the times). &lt;br /&gt;
&lt;br /&gt;
The power of CRC cards for OOP development is in the group session that employs them.  The use of CRC cards is an excellent way for people to begin to grasp the underlying idea of object oriented approach. CRC cards are used in a few steps of the software development process such as Analysis and Design.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Analysis===&lt;br /&gt;
&lt;br /&gt;
CRC cards and CRC card sessions are good at organizing and spreading domain knowledge in the analysis phase.  When building an object–oriented application, the focus of the CRC card sessions is on analyzing and describing the problem.  In this phase, the group identifies the objects that are relevant to the application.  Before going to the CRC card session, the team must be aware of the domain classes and frameworks that exist to help them model the problem. During the session, they can decide if the existing ones can be used for the new application.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Analysis phase:'''&lt;br /&gt;
&lt;br /&gt;
* People from all phases of the project are involved in the card sessions for problem modeling. The names of the classes and responsibilities are created, argued and agreed upon by the team members at the start itself in order to avoid conflicts later. This gives rise to common project and product vocabulary across different roles.&lt;br /&gt;
&lt;br /&gt;
* Domain knowledge already known is shared in the sessions. Also, missing domain knowledge is identified.&lt;br /&gt;
 &lt;br /&gt;
* Role plays are conducted during these sessions that help spread knowledge about OO concepts.&lt;br /&gt;
&lt;br /&gt;
* These sessions can be used to create a live prototype of what the application is supposed to do. This can be shown to clients as well so that the team receives feedback on their understanding of the requirements.&lt;br /&gt;
 &lt;br /&gt;
* A CRC card session will help the team walk through the requirements and identify any ambiguities.&lt;br /&gt;
&lt;br /&gt;
At the end of the analysis phase, the CRC elements that will be available are:&lt;br /&gt;
&lt;br /&gt;
* '''Classes:''' The classes identified in this phase directly reflect the concepts of the application that is being analyzed. It may not be modeled in terms of software system but it is useful in describing how the application works. However, at this stage the distinction between objects and classes may not be clear.&lt;br /&gt;
&lt;br /&gt;
* '''Responsibilities:'''  The responsibilities that are assigned to the classes in this phase are of relatively higher level.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Design===&lt;br /&gt;
 &lt;br /&gt;
During the CRC cards design sessions, other relevant classes are added, if any. &amp;quot;While an analysis must reflect the real world of the user, the design must reflect the real world of the implementers.&amp;quot;[5] A CRC card tool may be helpful for saving, illustrating and documenting a design.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Design phase:'''&lt;br /&gt;
&lt;br /&gt;
* These sessions help the team members concentrate on taking the design decisions for the application. These design decisions also include performance, efficiency and other constraints.&lt;br /&gt;
&lt;br /&gt;
* By walking through the scenarios that were seen during the analysis phase, the implementers can give the testers an overview of how the application should work.&lt;br /&gt;
&lt;br /&gt;
* Using CRC cards forces decision to be made up front in front of the team, thus any conflicts can be resolved right there.&lt;br /&gt;
&lt;br /&gt;
* Design constraints such as target environment, language, UI, performance etc., can be discussed during these sessions to check if the design can be implemented.&lt;br /&gt;
&lt;br /&gt;
==Summary==&lt;br /&gt;
Software for CRC cards are immensely helpful in designing and modeling software development using CRC cards.As the size of object-oriented system grow, it becomes increasingly difficult to model the problem with index based CRC cards. Thus an automated tool is required to maintain design and clear functionality.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Agile_Modeling Agile Modelling]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
[1] [http://c2.com/doc/oopsla89/paper.html  A Laboratory For Teaching Object-Oriented Thinking]&lt;br /&gt;
&lt;br /&gt;
[2] [http://www.extremeprogramming.org/rules/crccards.html CRC Cards]&lt;br /&gt;
&lt;br /&gt;
[3] [http://www.extremeprogramming.org/example/crcsim.html A Simulator for Coffee Maker]&lt;br /&gt;
&lt;br /&gt;
[4] [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html CRC Card for ATM]&lt;br /&gt;
&lt;br /&gt;
[5] &amp;quot;Using CRC Cards: An Informal Approach to Object-Oriented Development&amp;quot; by Nancy M.Wilkinson&lt;br /&gt;
&lt;br /&gt;
[6] [http://books.google.com/books?id=SGOyQai2TboC&amp;amp;printsec=frontcover&amp;amp;dq=CRC+card+book&amp;amp;hl=en&amp;amp;ei=xSOaTKSaNISclgfRqtkK&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=1&amp;amp;ved=0CDYQ6AEwAA#v=onepage&amp;amp;q&amp;amp;f=false The CRC card book] by David Bellin, Susan Suchman Simone&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html A Laboratory For Teaching Object-Oriented Thinking] by Ward Cunningham and Kent Beck&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Modelling CRC Cards]&lt;br /&gt;
* [http://www.excelsoftware.com/quickcrcwin.html Quick CRC]&lt;br /&gt;
* [http://www.indicthreads.com/1439/quick-introduction-to-agile-software-development Quick Introduction to Agile Software Development]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65516</id>
		<title>CSC/ECE 517 Fall 2012/ch1 1w11 ap</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65516"/>
		<updated>2012-09-22T02:33:27Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: /* Software for CRC Cards */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&amp;lt;b&amp;gt; CRC Cards, &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] cards are a brainstorming tool to enable collaboration across different teams or individuals in contribution to design, usually used in Object Oriented Software development. This was  proposed by &amp;lt;b&amp;gt;Ward Cunningham&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;Kent Beck&amp;lt;/b&amp;gt;&amp;lt;sup&amp;gt;[http://c2.com/doc/oopsla89/paper.html]&amp;lt;/sup&amp;gt;. The CRC card can be viewed as an index card, with the following details:&lt;br /&gt;
[[Image:crc-card.gif|frame|right|CRC Card Structure]]&lt;br /&gt;
&lt;br /&gt;
:* The Top of the card usually bears the name of the class.&lt;br /&gt;
:* The Left side of the card has the responsibilities of the class.&lt;br /&gt;
:* The Right side of the card has the collaborating classes corresponding to each of the responsibilities listed in the left side.&lt;br /&gt;
&lt;br /&gt;
Thus in general, a CRC session can be viewed as the interaction between a set of collaborating classes for a particular [http://en.wikipedia.org/wiki/Use_case Use case]. &amp;lt;br&amp;gt; &amp;lt;br&amp;gt; According to &amp;lt;sup&amp;gt;[http://www.extremeprogramming.org/rules/crccards.html]&amp;lt;/sup&amp;gt;&amp;lt;i&amp;gt;A CRC session proceeds with someone simulating the system by talking about which objects send messages to other objects. By stepping through the process' weaknesses and problems are easily uncovered. Design alternatives can be explored quickly by simulating the design being proposed.&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===A CRC Example===&lt;br /&gt;
To better understand how the CRC cards work together, let us consider a simple student enrollment problem,where we are required to model the students enrolled in different courses. We can easily define the &amp;lt;b&amp;gt;Student CRC Card&amp;lt;/b&amp;gt; as having attributes such as student name, student id and responsibilities that enable a student to enroll in a course or drop the course. In this particular instance, the collaborating class would be the &amp;lt;b&amp;gt;Course&amp;lt;/b&amp;gt; class. The &amp;lt;b&amp;gt;Course CRC Card&amp;lt;/b&amp;gt; can in turn be visualized as having its own responsibilities, such as having attributes like Course id, course name and the collaborating class would be the &amp;lt;b&amp;gt;Instructor &lt;br /&gt;
class&amp;lt;/b&amp;gt;. The CRC cards for the Student class and the Course Class are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[Image:Stud_enr_Crc.jpg|frame|center|Student and Course CRC Card]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There are also several practical designs that use the CRC card model to design Object oriented software design. The  [http://www.extremeprogramming.org/example/crcsim.html Simulator for Coffee Maker] explores an [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] approach combined with CRC card technique to come up with a design for the coffee maker.&lt;br /&gt;
&lt;br /&gt;
Another interesting approach using CRC cards is the design for the [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html ATM Machine]&lt;br /&gt;
&lt;br /&gt;
===Advantages of CRC cards===&lt;br /&gt;
There are a few advantages of CRC cards that make it a preferable model in many designs. Some of the advantages of the CRC card design method are&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:* CRC cards can allow designers to easily make audience understand a very complex system. In essence it allows for building more complex designs by slowly building the interactions between the collaborating classes, one by one.&lt;br /&gt;
:* CRC cards are a simple technique and it can be easily used by anyone with very little training and does not require any expensive computing resources(a board or a paper and a pen would suffice).&lt;br /&gt;
:* CRC is fundamentally a brainstorming tool, enabling different people in a team to come up with the design by collaborating, enabling everyone in the team to contribute&lt;br /&gt;
:* CRC can be used with other formal object oriented design methodologies such as [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] (an [http://en.wikipedia.org/wiki/Agile_Modeling Agile] development Technique) and can be used along with modeling languages such as [http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
&lt;br /&gt;
==Software for CRC Cards==&lt;br /&gt;
CRC cards have limited scope. If we go about designing a huge project, the scope may span many classes and there might be numerous interactions between them. The tedious task here is to maintain the CRC cards and formulate appropriate interaction between them. &lt;br /&gt;
We need software for CRC Cards for the following reasons:&lt;br /&gt;
:* &amp;lt;b&amp;gt;Designing Scenario:&amp;lt;/b&amp;gt;  A scenario represents a series of steps in which classes and objects communicate. There can be references to other scenarios. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Modeling :&amp;lt;/b&amp;gt;  Software provides an easy way to segregate cards and objects into different diagrams. Thus we can model our problem with different functionality very easily.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Simulation :&amp;lt;/b&amp;gt; Software can provide simulation of the design. This might include single-stepping a scenario forward or backwards or jumping to a specific location in the scenario stack of a multiple scenario simulation.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Synchronization and Dependencies:&amp;lt;/b&amp;gt; Software can maintain relationships between cards and scenarios as design changes take place. If a card references other cards or classes, any changes in those cards are generated automatically. Also any name changes and cross references between objects are instantly updated. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Revision history and [http://en.wikipedia.org/wiki/Revision_control Version Control] :&amp;lt;/b&amp;gt; Software for CRC cards supports changes to CRC cards. It is easy to model and keep track of all changes to a CRC card. This is extremely helpful in tracking design changes.&lt;br /&gt;
&lt;br /&gt;
==Designing Software==&lt;br /&gt;
The steps to design software for CRC cards are:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Create CRC Cards&amp;lt;/b&amp;gt; : A CRC model is usually created by an individual or small group of designers during the early phase of an object-oriented development project.The figure shows the design of hierarchy of classes. These set of class used for drawing objects are shown. We can see TShape class has a superclass called TObject and two subclasses, TBox and TCircle. Lets assume we create new class TWindow derived from the superclass TObject.  [[Image:Design.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Assign Responsibilities&amp;lt;/b&amp;gt; : Once a set of classes are defined, behaviors can be assigned that will provide the functions of the application. For example, the TShape card has responsibilities ''Initialize'' to create it and ''Draw'' to illustrate it on the diagram.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Add Attributes&amp;lt;/b&amp;gt; : Attributes of classes may also be identified in a CRC Card.The TShape class has attributes fPosition, fType and fSelected.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Define and simulate Scenario&amp;lt;/b&amp;gt; : A scenario describes a sequence of steps in the design using the responsibilities of a group of collaborating classes. Collaboration between classes refers to a client object that uses a responsibility performed by a server object. Often a class must call upon several collaborating classes to implement one of its responsibilities.A scenario describes what happens in the system from a high-level, user's point of view.&lt;br /&gt;
[[Image:Scenario.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
Consider situation to the right. We have defined two CRC cards with their responsibility. A scenario defines several steps. Each step in a scenario has a Client, Server and Responsibility field. For each step, a client class uses a responsibility of a server class&lt;br /&gt;
&lt;br /&gt;
The Open Document scenario in the picture references the Initialize Document sub-scenario by specifying its server class ''Document'' in the server field and its scenario name in the Responsibility field. The first step in the Initialize Document sub-scenario uses ''Document'' as the server class name. By single-stepping forwards, backwards or through each sub-scenario, bugs in the design can be identified and corrected early.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Partition the Design&amp;lt;/b&amp;gt; : As the number of CRC cards in the design grow, they can be grouped by function. By using Software for CRC cards,we can draw separate diagrams to partition the model into different subject areas. &lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;[http://www.google.com/search?q=what+is+an+inheritance+graph&amp;amp;rlz=1C1CHFX_enUS460US460&amp;amp;sugexp=chrome,mod=14&amp;amp;sourceid=chrome&amp;amp;ie=UTF-8#hl=en&amp;amp;rlz=1C1CHFX_enUS460US460&amp;amp;q=inheritance+graph&amp;amp;tbs=dfn:1&amp;amp;tbo=u&amp;amp;sa=X&amp;amp;ei=IyFdUK_wAZLw8ATD8oHgCw&amp;amp;ved=0CB8QkQ4&amp;amp;bav=on.2,or.r_gc.r_pw.r_qf.&amp;amp;fp=99d6414d69e5a888&amp;amp;biw=1517&amp;amp;bih=783 Inheritance Graph]&amp;lt;/b&amp;gt; : An automated tool can generate an inheritance graph from information on CRC cards. This diagram can concisely illustrate the big picture of a large project that might contain hundreds of classes and dozens of diagrams.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Verify Your Work &amp;lt;/b&amp;gt; : Creating and simulating scenarios will help verify that a design is correct and complete. A CRC software can perform other error checks to locate design problems. For example, responsibilities that are not used in any scenarios may indicate that the design is incomplete or perhaps the responsibility isn't needed. Likewise, a card that is not used by any collaboration may not be needed.&lt;br /&gt;
&lt;br /&gt;
==Software Development Process for Object Oriented Development&amp;lt;sup&amp;gt;[6]&amp;lt;/sup&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
Software Development Life Cycles are different for a standard development process and for Object Oriented development. This difference needs to be understood in order to know how to meet the benchmarks set for the project. There are multiple processes that are used in software development, the most common ones in use being Waterfall model and Spiral model. The Waterfall model is progression based and the Spiral model is iterative.&lt;br /&gt;
&lt;br /&gt;
We need to understand that the uniqueness of Object Oriented SDLCs comes from the fact that it is more user centric as compared to standard SDLCs that are more system centric. We will now see which models work for Object Oriented SDLCs (OO SDLCs) and which don’t. CRC cards play a very important role in an Object Oriented SDLC. Thus, figuring out which models work well for OO SDLCs will result in understanding which models use CRC cards and why.&lt;br /&gt;
 &lt;br /&gt;
====The Waterfall Model====&lt;br /&gt;
&lt;br /&gt;
The Waterfall model is implemented in multiple phases with each phase having a clear demarcation in terms of its functionality and deliverable. It uses clear stepping stones to come up with deliverables for each deadline. In this case, there are multiple ways to measure progress and methods by which to audit internally and apply checkpoints.&lt;br /&gt;
&lt;br /&gt;
The downside of the Waterfall model lies in the fact that it is a very rigid model that does not offer much in terms of leeway when it comes to deliverables and what each phase in the cycle has to offer. The process is also overly mechanical and over time, just ends up being boring.&lt;br /&gt;
&lt;br /&gt;
Owing to the emphasis on checkpoints and deliverables with strict deadlines, in most cases the analysis and design phases are usually cut short and thus, the project may veer very far from reality. The users are involved only in the requirement gathering phase. This might result in mistranslation of the requirements of the user into what may be an amazing final product but something that the user did not even ask for.&lt;br /&gt;
 &lt;br /&gt;
====The Spiral Model====&lt;br /&gt;
This model iteratively goes through the phases of analysis, design, prototyping and testing after the initial requirements gathering phase. With each iteration, the product is improved based on the feedback from testing in the previous iteration. If required, the outcome of each phase is analyzed, revised and the next prototype is developed after the design is revised, if pertinent. The products from the first phase are not abandoned, they are revised. Evidently, this model is non-linear in nature.&lt;br /&gt;
&lt;br /&gt;
After the first pass through the checkpoint, we can conclude that the work so far is adequate, but not final. The model places emphasis on the iterative process and on the development of standard prototypes at the end of each iteration. At the end of every cycle, we notice the shortcomings from the previous cycle and might end up having to redo all the work in the previous cycle. This proves to be a complete waste of time and effort. All the effort now goes into developing the end point for an older cycle, which makes the model ineffective for the current cycle.&lt;br /&gt;
&lt;br /&gt;
One of the major drawbacks of such a non linear model is that the cost effectiveness and risk analysis cannot be analyzed thoroughly.&lt;br /&gt;
 &lt;br /&gt;
====Why CRC cards are not useful in Waterfall and Spiral Models====&lt;br /&gt;
&lt;br /&gt;
The strength of OO model depends on the idea that, here, design and deployment come together. In the case of a spiral model, this works to make the spiral tighter. Since the waterfall model places over importance on deliverables and user involvement is minimal, which is one of the key focuses of OO SLDCs using CRC cards, the model is considered ineffective. The Spiral model involves multiple revisions of the same idea. When a set of cards have been developed, it would make sense to refine the idea presented in the card but not to redefine them over and over, which may be the case. This does not serve the purpose of actually convening a CRC discussion among the team to draw up cards corresponding to the user requirement. Moreover, in the case of the Spiral model, we would need to convene multiple such meetings at each iteration, which would drastically bring down the overall productivity of the team.&lt;br /&gt;
&lt;br /&gt;
==CRC Cards in Software Development Process==&lt;br /&gt;
&lt;br /&gt;
===Agile Methodology and CRC Cards===&lt;br /&gt;
&lt;br /&gt;
Agile development is a model that has resurfaced and is gaining fame for its incremental cum iterative process. The iteration is carried over the processes of discovery, analysis, design and coding. In each iteration, the old model is worked on in each of the overlapping mini-cycles. The overlap of the cycles makes the process apparently iterative in nature. The model is considered incremental since every step acts as a value-add and this is emphasized by the capacity of classes for reuse. The idea that each phase is repeated ensures that the project is constantly working on a higher level of understanding. Moreover, the OOPS concept of reuse can be used to our advantage such that when we are continuously using OO development models in all our projects, the next implementation can be started  far ahead in the SDLC.&lt;br /&gt;
&lt;br /&gt;
The model focuses on analysis and design phase predominantly. Within each of these are mini phases of analysis-&amp;gt;prototype-&amp;gt;revision-&amp;gt; implementation cycles. The advantage of this model compared to other models described is that, being incremental, this also results in tightening of the spiral at the end of each iteration using concepts such as reusability and polymorphism. Thus, the progression from one point to another in the cycle is seamless from start to deployment.&lt;br /&gt;
&lt;br /&gt;
CRC cards can be very effectively and efficiently used in the Agile model of OO SDLC owing to the fact that it is incremental as well as iterative and not just a repetitive process. Thus, we would not have to redefine the cards from the scratch at any point. Being incremental, we would refine our current model and proceed to refine the entire system as a whole at the end of all iterations. We would essentially be adding value to the cards written out in the previous cycle and if perfected, would never have to discard cards from any of the precious cycles.&lt;br /&gt;
            &lt;br /&gt;
Agile also practices active customer involvement. In every phase, the user is involved. This is one of the key characteristics of the CRC card design method. This not only ensures that the final product is as per the customer's requirements, but also that the customer is thoroughly satisfied, since they are aware of the changes and increments at each level. Another key aspect of Agile methodology is that it is feature driven. A CRC card holds details as to the feature of each class and how it collaborates with the rest of the system. Since this information is readily available to the developer and is highly fine-tuned by the end of the SDLC process, the cards can guarantee focus on 80/20 principle (i.e. pay more attention to 20% of the features which will used 80% of the times). &lt;br /&gt;
&lt;br /&gt;
The power of CRC cards for OOP development is in the group session that employs them.  The use of CRC cards is an excellent way for people to begin to grasp the underlying idea of object oriented approach. CRC cards are used in a few steps of the software development process such as Analysis and Design.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Analysis===&lt;br /&gt;
&lt;br /&gt;
CRC cards and CRC card sessions are good at organizing and spreading domain knowledge in the analysis phase.  When building an object–oriented application, the focus of the CRC card sessions is on analyzing and describing the problem.  In this phase, the group identifies the objects that are relevant to the application.  Before going to the CRC card session, the team must be aware of the domain classes and frameworks that exist to help them model the problem. During the session, they can decide if the existing ones can be used for the new application.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Analysis phase:'''&lt;br /&gt;
&lt;br /&gt;
* People from all phases of the project are involved in the card sessions for problem modeling. The names of the classes and responsibilities are created, argued and agreed upon by the team members at the start itself in order to avoid conflicts later. This gives rise to common project and product vocabulary across different roles.&lt;br /&gt;
&lt;br /&gt;
* Domain knowledge already known is shared in the sessions. Also, missing domain knowledge is identified.&lt;br /&gt;
 &lt;br /&gt;
* Role plays are conducted during these sessions that help spread knowledge about OO concepts.&lt;br /&gt;
&lt;br /&gt;
* These sessions can be used to create a live prototype of what the application is supposed to do. This can be shown to clients as well so that the team receives feedback on their understanding of the requirements.&lt;br /&gt;
 &lt;br /&gt;
* A CRC card session will help the team walk through the requirements and identify any ambiguities.&lt;br /&gt;
&lt;br /&gt;
At the end of the analysis phase, the CRC elements that will be available are:&lt;br /&gt;
&lt;br /&gt;
* '''Classes:''' The classes identified in this phase directly reflect the concepts of the application that is being analyzed. It may not be modeled in terms of software system but it is useful in describing how the application works. However, at this stage the distinction between objects and classes may not be clear.&lt;br /&gt;
&lt;br /&gt;
* '''Responsibilities:'''  The responsibilities that are assigned to the classes in this phase are of relatively higher level.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Design===&lt;br /&gt;
 &lt;br /&gt;
During the CRC cards design sessions, other relevant classes are added, if any. &amp;quot;While an analysis must reflect the real world of the user, the design must reflect the real world of the implementers.&amp;quot;[5] A CRC card tool may be helpful for saving, illustrating and documenting a design.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Design phase:'''&lt;br /&gt;
&lt;br /&gt;
* These sessions help the team members concentrate on taking the design decisions for the application. These design decisions also include performance, efficiency and other constraints.&lt;br /&gt;
&lt;br /&gt;
* By walking through the scenarios that were seen during the analysis phase, the implementers can give the testers an overview of how the application should work.&lt;br /&gt;
&lt;br /&gt;
* Using CRC cards forces decision to be made up front in front of the team, thus any conflicts can be resolved right there.&lt;br /&gt;
&lt;br /&gt;
* Design constraints such as target environment, language, UI, performance etc., can be discussed during these sessions to check if the design can be implemented.&lt;br /&gt;
&lt;br /&gt;
==Summary==&lt;br /&gt;
Software for CRC cards are immensely helpful in designing and modeling software development using CRC cards.As the size of object-oriented system grow, it becomes increasingly difficult to model the problem with index based CRC cards. Thus an automated tool is required to maintain design and clear functionality.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Agile_Modeling Agile Modelling]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
[1] [http://c2.com/doc/oopsla89/paper.html  A Laboratory For Teaching Object-Oriented Thinking]&lt;br /&gt;
&lt;br /&gt;
[2] [http://www.extremeprogramming.org/rules/crccards.html CRC Cards]&lt;br /&gt;
&lt;br /&gt;
[3] [http://www.extremeprogramming.org/example/crcsim.html A Simulator for Coffee Maker]&lt;br /&gt;
&lt;br /&gt;
[4] [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html CRC Card for ATM]&lt;br /&gt;
&lt;br /&gt;
[5] &amp;quot;Using CRC Cards: An Informal Approach to Object-Oriented Development&amp;quot; by Nancy M.Wilkinson&lt;br /&gt;
&lt;br /&gt;
[6] [http://books.google.com/books?id=SGOyQai2TboC&amp;amp;printsec=frontcover&amp;amp;dq=CRC+card+book&amp;amp;hl=en&amp;amp;ei=xSOaTKSaNISclgfRqtkK&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=1&amp;amp;ved=0CDYQ6AEwAA#v=onepage&amp;amp;q&amp;amp;f=false The CRC card book] by David Bellin, Susan Suchman Simone&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html A Laboratory For Teaching Object-Oriented Thinking] by Ward Cunningham and Kent Beck&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Modelling CRC Cards]&lt;br /&gt;
* [http://www.excelsoftware.com/quickcrcwin.html Quick CRC]&lt;br /&gt;
* [http://www.indicthreads.com/1439/quick-introduction-to-agile-software-development Quick Introduction to Agile Software Development]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65515</id>
		<title>CSC/ECE 517 Fall 2012/ch1 1w11 ap</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65515"/>
		<updated>2012-09-22T02:28:31Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&amp;lt;b&amp;gt; CRC Cards, &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] cards are a brainstorming tool to enable collaboration across different teams or individuals in contribution to design, usually used in Object Oriented Software development. This was  proposed by &amp;lt;b&amp;gt;Ward Cunningham&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;Kent Beck&amp;lt;/b&amp;gt;&amp;lt;sup&amp;gt;[http://c2.com/doc/oopsla89/paper.html]&amp;lt;/sup&amp;gt;. The CRC card can be viewed as an index card, with the following details:&lt;br /&gt;
[[Image:crc-card.gif|frame|right|CRC Card Structure]]&lt;br /&gt;
&lt;br /&gt;
:* The Top of the card usually bears the name of the class.&lt;br /&gt;
:* The Left side of the card has the responsibilities of the class.&lt;br /&gt;
:* The Right side of the card has the collaborating classes corresponding to each of the responsibilities listed in the left side.&lt;br /&gt;
&lt;br /&gt;
Thus in general, a CRC session can be viewed as the interaction between a set of collaborating classes for a particular [http://en.wikipedia.org/wiki/Use_case Use case]. &amp;lt;br&amp;gt; &amp;lt;br&amp;gt; According to &amp;lt;sup&amp;gt;[http://www.extremeprogramming.org/rules/crccards.html]&amp;lt;/sup&amp;gt;&amp;lt;i&amp;gt;A CRC session proceeds with someone simulating the system by talking about which objects send messages to other objects. By stepping through the process' weaknesses and problems are easily uncovered. Design alternatives can be explored quickly by simulating the design being proposed.&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===A CRC Example===&lt;br /&gt;
To better understand how the CRC cards work together, let us consider a simple student enrollment problem,where we are required to model the students enrolled in different courses. We can easily define the &amp;lt;b&amp;gt;Student CRC Card&amp;lt;/b&amp;gt; as having attributes such as student name, student id and responsibilities that enable a student to enroll in a course or drop the course. In this particular instance, the collaborating class would be the &amp;lt;b&amp;gt;Course&amp;lt;/b&amp;gt; class. The &amp;lt;b&amp;gt;Course CRC Card&amp;lt;/b&amp;gt; can in turn be visualized as having its own responsibilities, such as having attributes like Course id, course name and the collaborating class would be the &amp;lt;b&amp;gt;Instructor &lt;br /&gt;
class&amp;lt;/b&amp;gt;. The CRC cards for the Student class and the Course Class are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[Image:Stud_enr_Crc.jpg|frame|center|Student and Course CRC Card]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There are also several practical designs that use the CRC card model to design Object oriented software design. The  [http://www.extremeprogramming.org/example/crcsim.html Simulator for Coffee Maker] explores an [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] approach combined with CRC card technique to come up with a design for the coffee maker.&lt;br /&gt;
&lt;br /&gt;
Another interesting approach using CRC cards is the design for the [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html ATM Machine]&lt;br /&gt;
&lt;br /&gt;
===Advantages of CRC cards===&lt;br /&gt;
There are a few advantages of CRC cards that make it a preferable model in many designs. Some of the advantages of the CRC card design method are&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:* CRC cards can allow designers to easily make audience understand a very complex system. In essence it allows for building more complex designs by slowly building the interactions between the collaborating classes, one by one.&lt;br /&gt;
:* CRC cards are a simple technique and it can be easily used by anyone with very little training and does not require any expensive computing resources(a board or a paper and a pen would suffice).&lt;br /&gt;
:* CRC is fundamentally a brainstorming tool, enabling different people in a team to come up with the design by collaborating, enabling everyone in the team to contribute&lt;br /&gt;
:* CRC can be used with other formal object oriented design methodologies such as [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] (an [http://en.wikipedia.org/wiki/Agile_Modeling Agile] development Technique) and can be used along with modeling languages such as [http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
&lt;br /&gt;
==Software for CRC Cards==&lt;br /&gt;
CRC cards have limited scope. If we go about designing a huge project, the scope spans many classes and interactions between them. The tedious task here is to maintain the CRC cards and properly formulate interaction between them. &lt;br /&gt;
We need software for CRC Cards for the following reasons:&lt;br /&gt;
:* &amp;lt;b&amp;gt;Designing Scenario:&amp;lt;/b&amp;gt;  A scenario represents series of steps in which classes and objects communicate. There can be references to other cards or scenarios. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Modeling :&amp;lt;/b&amp;gt;  Software provides an easy way to segregate cards and objects into different diagrams. Thus we can model our problem with different functionality very easily.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Simulation :&amp;lt;/b&amp;gt; Software can provide simulation of the design. This might include single-stepping a scenario forwards/backwards or jumping to a specific location in the scenario stack of a multiple scenario simulation&lt;br /&gt;
:* &amp;lt;b&amp;gt;Synchronization and Dependencies:&amp;lt;/b&amp;gt; Software can maintain relationships between cards, scenarios as design changes take place. If a card references other cards or classes, those cards are generated automatically. Also any name changes and cross references between objects are instantly updated. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Revision history and Version Control :&amp;lt;/b&amp;gt; Software for CRC cards supports changes to CRC cards. It is easy to model and keep track of all changes to a CRC card. This is extremely helpful in tracking the design changes in CRC cards.&lt;br /&gt;
&lt;br /&gt;
==Designing Software==&lt;br /&gt;
The steps to design software for CRC cards are:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Create CRC Cards&amp;lt;/b&amp;gt; : A CRC model is usually created by an individual or small group of designers during the early phase of an object-oriented development project.The figure shows the design of hierarchy of classes. These set of class used for drawing objects are shown. We can see TShape class has a superclass called TObject and two subclasses, TBox and TCircle. Lets assume we create new class TWindow derived from the superclass TObject.  [[Image:Design.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Assign Responsibilities&amp;lt;/b&amp;gt; : Once a set of classes are defined, behaviors can be assigned that will provide the functions of the application. For example, the TShape card has responsibilities ''Initialize'' to create it and ''Draw'' to illustrate it on the diagram.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Add Attributes&amp;lt;/b&amp;gt; : Attributes of classes may also be identified in a CRC Card.The TShape class has attributes fPosition, fType and fSelected.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Define and simulate Scenario&amp;lt;/b&amp;gt; : A scenario describes a sequence of steps in the design using the responsibilities of a group of collaborating classes. Collaboration between classes refers to a client object that uses a responsibility performed by a server object. Often a class must call upon several collaborating classes to implement one of its responsibilities.A scenario describes what happens in the system from a high-level, user's point of view.&lt;br /&gt;
[[Image:Scenario.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
Consider situation to the right. We have defined two CRC cards with their responsibility. A scenario defines several steps. Each step in a scenario has a Client, Server and Responsibility field. For each step, a client class uses a responsibility of a server class&lt;br /&gt;
&lt;br /&gt;
The Open Document scenario in the picture references the Initialize Document sub-scenario by specifying its server class ''Document'' in the server field and its scenario name in the Responsibility field. The first step in the Initialize Document sub-scenario uses ''Document'' as the server class name. By single-stepping forwards, backwards or through each sub-scenario, bugs in the design can be identified and corrected early.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Partition the Design&amp;lt;/b&amp;gt; : As the number of CRC cards in the design grow, they can be grouped by function. By using Software for CRC cards,we can draw separate diagrams to partition the model into different subject areas. &lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;[http://www.google.com/search?q=what+is+an+inheritance+graph&amp;amp;rlz=1C1CHFX_enUS460US460&amp;amp;sugexp=chrome,mod=14&amp;amp;sourceid=chrome&amp;amp;ie=UTF-8#hl=en&amp;amp;rlz=1C1CHFX_enUS460US460&amp;amp;q=inheritance+graph&amp;amp;tbs=dfn:1&amp;amp;tbo=u&amp;amp;sa=X&amp;amp;ei=IyFdUK_wAZLw8ATD8oHgCw&amp;amp;ved=0CB8QkQ4&amp;amp;bav=on.2,or.r_gc.r_pw.r_qf.&amp;amp;fp=99d6414d69e5a888&amp;amp;biw=1517&amp;amp;bih=783 Inheritance Graph]&amp;lt;/b&amp;gt; : An automated tool can generate an inheritance graph from information on CRC cards. This diagram can concisely illustrate the big picture of a large project that might contain hundreds of classes and dozens of diagrams.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Verify Your Work &amp;lt;/b&amp;gt; : Creating and simulating scenarios will help verify that a design is correct and complete. A CRC software can perform other error checks to locate design problems. For example, responsibilities that are not used in any scenarios may indicate that the design is incomplete or perhaps the responsibility isn't needed. Likewise, a card that is not used by any collaboration may not be needed.&lt;br /&gt;
&lt;br /&gt;
==Software Development Process for Object Oriented Development&amp;lt;sup&amp;gt;[6]&amp;lt;/sup&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
Software Development Life Cycles are different for a standard development process and for Object Oriented development. This difference needs to be understood in order to know how to meet the benchmarks set for the project. There are multiple processes that are used in software development, the most common ones in use being Waterfall model and Spiral model. The Waterfall model is progression based and the Spiral model is iterative.&lt;br /&gt;
&lt;br /&gt;
We need to understand that the uniqueness of Object Oriented SDLCs comes from the fact that it is more user centric as compared to standard SDLCs that are more system centric. We will now see which models work for Object Oriented SDLCs (OO SDLCs) and which don’t. CRC cards play a very important role in an Object Oriented SDLC. Thus, figuring out which models work well for OO SDLCs will result in understanding which models use CRC cards and why.&lt;br /&gt;
 &lt;br /&gt;
====The Waterfall Model====&lt;br /&gt;
&lt;br /&gt;
The Waterfall model is implemented in multiple phases with each phase having a clear demarcation in terms of its functionality and deliverable. It uses clear stepping stones to come up with deliverables for each deadline. In this case, there are multiple ways to measure progress and methods by which to audit internally and apply checkpoints.&lt;br /&gt;
&lt;br /&gt;
The downside of the Waterfall model lies in the fact that it is a very rigid model that does not offer much in terms of leeway when it comes to deliverables and what each phase in the cycle has to offer. The process is also overly mechanical and over time, just ends up being boring.&lt;br /&gt;
&lt;br /&gt;
Owing to the emphasis on checkpoints and deliverables with strict deadlines, in most cases the analysis and design phases are usually cut short and thus, the project may veer very far from reality. The users are involved only in the requirement gathering phase. This might result in mistranslation of the requirements of the user into what may be an amazing final product but something that the user did not even ask for.&lt;br /&gt;
 &lt;br /&gt;
====The Spiral Model====&lt;br /&gt;
This model iteratively goes through the phases of analysis, design, prototyping and testing after the initial requirements gathering phase. With each iteration, the product is improved based on the feedback from testing in the previous iteration. If required, the outcome of each phase is analyzed, revised and the next prototype is developed after the design is revised, if pertinent. The products from the first phase are not abandoned, they are revised. Evidently, this model is non-linear in nature.&lt;br /&gt;
&lt;br /&gt;
After the first pass through the checkpoint, we can conclude that the work so far is adequate, but not final. The model places emphasis on the iterative process and on the development of standard prototypes at the end of each iteration. At the end of every cycle, we notice the shortcomings from the previous cycle and might end up having to redo all the work in the previous cycle. This proves to be a complete waste of time and effort. All the effort now goes into developing the end point for an older cycle, which makes the model ineffective for the current cycle.&lt;br /&gt;
&lt;br /&gt;
One of the major drawbacks of such a non linear model is that the cost effectiveness and risk analysis cannot be analyzed thoroughly.&lt;br /&gt;
 &lt;br /&gt;
====Why CRC cards are not useful in Waterfall and Spiral Models====&lt;br /&gt;
&lt;br /&gt;
The strength of OO model depends on the idea that, here, design and deployment come together. In the case of a spiral model, this works to make the spiral tighter. Since the waterfall model places over importance on deliverables and user involvement is minimal, which is one of the key focuses of OO SLDCs using CRC cards, the model is considered ineffective. The Spiral model involves multiple revisions of the same idea. When a set of cards have been developed, it would make sense to refine the idea presented in the card but not to redefine them over and over, which may be the case. This does not serve the purpose of actually convening a CRC discussion among the team to draw up cards corresponding to the user requirement. Moreover, in the case of the Spiral model, we would need to convene multiple such meetings at each iteration, which would drastically bring down the overall productivity of the team.&lt;br /&gt;
&lt;br /&gt;
==CRC Cards in Software Development Process==&lt;br /&gt;
&lt;br /&gt;
===Agile Methodology and CRC Cards===&lt;br /&gt;
&lt;br /&gt;
Agile development is a model that has resurfaced and is gaining fame for its incremental cum iterative process. The iteration is carried over the processes of discovery, analysis, design and coding. In each iteration, the old model is worked on in each of the overlapping mini-cycles. The overlap of the cycles makes the process apparently iterative in nature. The model is considered incremental since every step acts as a value-add and this is emphasized by the capacity of classes for reuse. The idea that each phase is repeated ensures that the project is constantly working on a higher level of understanding. Moreover, the OOPS concept of reuse can be used to our advantage such that when we are continuously using OO development models in all our projects, the next implementation can be started  far ahead in the SDLC.&lt;br /&gt;
&lt;br /&gt;
The model focuses on analysis and design phase predominantly. Within each of these are mini phases of analysis-&amp;gt;prototype-&amp;gt;revision-&amp;gt; implementation cycles. The advantage of this model compared to other models described is that, being incremental, this also results in tightening of the spiral at the end of each iteration using concepts such as reusability and polymorphism. Thus, the progression from one point to another in the cycle is seamless from start to deployment.&lt;br /&gt;
&lt;br /&gt;
CRC cards can be very effectively and efficiently used in the Agile model of OO SDLC owing to the fact that it is incremental as well as iterative and not just a repetitive process. Thus, we would not have to redefine the cards from the scratch at any point. Being incremental, we would refine our current model and proceed to refine the entire system as a whole at the end of all iterations. We would essentially be adding value to the cards written out in the previous cycle and if perfected, would never have to discard cards from any of the precious cycles.&lt;br /&gt;
            &lt;br /&gt;
Agile also practices active customer involvement. In every phase, the user is involved. This is one of the key characteristics of the CRC card design method. This not only ensures that the final product is as per the customer's requirements, but also that the customer is thoroughly satisfied, since they are aware of the changes and increments at each level. Another key aspect of Agile methodology is that it is feature driven. A CRC card holds details as to the feature of each class and how it collaborates with the rest of the system. Since this information is readily available to the developer and is highly fine-tuned by the end of the SDLC process, the cards can guarantee focus on 80/20 principle (i.e. pay more attention to 20% of the features which will used 80% of the times). &lt;br /&gt;
&lt;br /&gt;
The power of CRC cards for OOP development is in the group session that employs them.  The use of CRC cards is an excellent way for people to begin to grasp the underlying idea of object oriented approach. CRC cards are used in a few steps of the software development process such as Analysis and Design.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Analysis===&lt;br /&gt;
&lt;br /&gt;
CRC cards and CRC card sessions are good at organizing and spreading domain knowledge in the analysis phase.  When building an object–oriented application, the focus of the CRC card sessions is on analyzing and describing the problem.  In this phase, the group identifies the objects that are relevant to the application.  Before going to the CRC card session, the team must be aware of the domain classes and frameworks that exist to help them model the problem. During the session, they can decide if the existing ones can be used for the new application.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Analysis phase:'''&lt;br /&gt;
&lt;br /&gt;
* People from all phases of the project are involved in the card sessions for problem modeling. The names of the classes and responsibilities are created, argued and agreed upon by the team members at the start itself in order to avoid conflicts later. This gives rise to common project and product vocabulary across different roles.&lt;br /&gt;
&lt;br /&gt;
* Domain knowledge already known is shared in the sessions. Also, missing domain knowledge is identified.&lt;br /&gt;
 &lt;br /&gt;
* Role plays are conducted during these sessions that help spread knowledge about OO concepts.&lt;br /&gt;
&lt;br /&gt;
* These sessions can be used to create a live prototype of what the application is supposed to do. This can be shown to clients as well so that the team receives feedback on their understanding of the requirements.&lt;br /&gt;
 &lt;br /&gt;
* A CRC card session will help the team walk through the requirements and identify any ambiguities.&lt;br /&gt;
&lt;br /&gt;
At the end of the analysis phase, the CRC elements that will be available are:&lt;br /&gt;
&lt;br /&gt;
* '''Classes:''' The classes identified in this phase directly reflect the concepts of the application that is being analyzed. It may not be modeled in terms of software system but it is useful in describing how the application works. However, at this stage the distinction between objects and classes may not be clear.&lt;br /&gt;
&lt;br /&gt;
* '''Responsibilities:'''  The responsibilities that are assigned to the classes in this phase are of relatively higher level.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Design===&lt;br /&gt;
 &lt;br /&gt;
During the CRC cards design sessions, other relevant classes are added, if any. &amp;quot;While an analysis must reflect the real world of the user, the design must reflect the real world of the implementers.&amp;quot;[5] A CRC card tool may be helpful for saving, illustrating and documenting a design.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Design phase:'''&lt;br /&gt;
&lt;br /&gt;
* These sessions help the team members concentrate on taking the design decisions for the application. These design decisions also include performance, efficiency and other constraints.&lt;br /&gt;
&lt;br /&gt;
* By walking through the scenarios that were seen during the analysis phase, the implementers can give the testers an overview of how the application should work.&lt;br /&gt;
&lt;br /&gt;
* Using CRC cards forces decision to be made up front in front of the team, thus any conflicts can be resolved right there.&lt;br /&gt;
&lt;br /&gt;
* Design constraints such as target environment, language, UI, performance etc., can be discussed during these sessions to check if the design can be implemented.&lt;br /&gt;
&lt;br /&gt;
==Summary==&lt;br /&gt;
Software for CRC cards are immensely helpful in designing and modeling software development using CRC cards.As the size of object-oriented system grow, it becomes increasingly difficult to model the problem with index based CRC cards. Thus an automated tool is required to maintain design and clear functionality.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Agile_Modeling Agile Modelling]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
[1] [http://c2.com/doc/oopsla89/paper.html  A Laboratory For Teaching Object-Oriented Thinking]&lt;br /&gt;
&lt;br /&gt;
[2] [http://www.extremeprogramming.org/rules/crccards.html CRC Cards]&lt;br /&gt;
&lt;br /&gt;
[3] [http://www.extremeprogramming.org/example/crcsim.html A Simulator for Coffee Maker]&lt;br /&gt;
&lt;br /&gt;
[4] [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html CRC Card for ATM]&lt;br /&gt;
&lt;br /&gt;
[5] &amp;quot;Using CRC Cards: An Informal Approach to Object-Oriented Development&amp;quot; by Nancy M.Wilkinson&lt;br /&gt;
&lt;br /&gt;
[6] [http://books.google.com/books?id=SGOyQai2TboC&amp;amp;printsec=frontcover&amp;amp;dq=CRC+card+book&amp;amp;hl=en&amp;amp;ei=xSOaTKSaNISclgfRqtkK&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=1&amp;amp;ved=0CDYQ6AEwAA#v=onepage&amp;amp;q&amp;amp;f=false The CRC card book] by David Bellin, Susan Suchman Simone&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html A Laboratory For Teaching Object-Oriented Thinking] by Ward Cunningham and Kent Beck&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Modelling CRC Cards]&lt;br /&gt;
* [http://www.excelsoftware.com/quickcrcwin.html Quick CRC]&lt;br /&gt;
* [http://www.indicthreads.com/1439/quick-introduction-to-agile-software-development Quick Introduction to Agile Software Development]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65132</id>
		<title>CSC/ECE 517 Fall 2012/ch1 1w11 ap</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=65132"/>
		<updated>2012-09-15T03:21:45Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&amp;lt;b&amp;gt; CRC Cards, &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] cards are a brainstorming tool to enable collaboration across different teams or individuals in contribution to design, usually used in Object Oriented Software development. This was  proposed by &amp;lt;b&amp;gt;Ward Cunningham&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;Kent Beck&amp;lt;/b&amp;gt;&amp;lt;sup&amp;gt;[http://c2.com/doc/oopsla89/paper.html]&amp;lt;/sup&amp;gt;. The CRC card can be viewed as an index card, with the following details:&lt;br /&gt;
[[Image:crc-card.gif|frame|right|CRC Card Structure]]&lt;br /&gt;
&lt;br /&gt;
:* The Top of the card usually bears the name of the class.&lt;br /&gt;
:* The Left side of the card has the responsibilities of the class.&lt;br /&gt;
:* The Right side of the card has the collaborating classes corresponding to each of the responsibilities listed in the left side.&lt;br /&gt;
&lt;br /&gt;
Thus in general, a CRC session can be viewed as the interaction between a set of collaborating classes for a particular [http://en.wikipedia.org/wiki/Use_case Use case]. &amp;lt;br&amp;gt; &amp;lt;br&amp;gt; According to &amp;lt;sup&amp;gt;[http://www.extremeprogramming.org/rules/crccards.html]&amp;lt;/sup&amp;gt;&amp;lt;i&amp;gt;A CRC session proceeds with someone simulating the system by talking about which objects send messages to other objects. By stepping through the process' weaknesses and problems are easily uncovered. Design alternatives can be explored quickly by simulating the design being proposed.&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===A CRC Example===&lt;br /&gt;
To better understand how the CRC cards work together, let us consider a simple student enrollment problem,where we are required to model the students enrolled in different courses. We can easily define the &amp;lt;b&amp;gt;Student CRC Card&amp;lt;/b&amp;gt; as having attributes such as student name, student id and responsibilities that enable a student to enroll in a course or drop the course. In this particular instance, the collaborating class would be the &amp;lt;b&amp;gt;Course&amp;lt;/b&amp;gt; class. The &amp;lt;b&amp;gt;Course CRC Card&amp;lt;/b&amp;gt; can in turn be visualized as having its own responsibilities, such as having attributes like Course id, course name and the collaborating class would be the &amp;lt;b&amp;gt;Instructor &lt;br /&gt;
class&amp;lt;/b&amp;gt;. The CRC cards for the Student class and the Course Class are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[Image:Stud_enr_Crc.jpg|frame|center|Student and Course CRC Card]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There are also several practical designs that use the CRC card model to design Object oriented software design. The  [http://www.extremeprogramming.org/example/crcsim.html Simulator for Coffee Maker] explores an [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] approach combined with CRC card technique to come up with a design for the coffee maker.&lt;br /&gt;
&lt;br /&gt;
Another interesting approach using CRC cards is the design for the [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html ATM Machine]&lt;br /&gt;
&lt;br /&gt;
===Advantages of CRC cards===&lt;br /&gt;
There are a few advantages of CRC cards that make it a preferable model in many designs. Some of the advantages of the CRC card design method are&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:* CRC cards can allow designers to easily make audience understand a very complex system. In essence it allows for building more complex designs by slowly building the interactions between the collaborating classes, one by one.&lt;br /&gt;
:* CRC cards are a simple technique and it can be easily used by anyone with very little training and does not require any expensive computing resources(a board or a paper and a pen would suffice).&lt;br /&gt;
:* CRC is fundamentally a brainstorming tool, enabling different people in a team to come up with the design by collaborating, enabling everyone in the team to contribute&lt;br /&gt;
:* CRC can be used with other formal object oriented design methodologies such as [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] (an [http://en.wikipedia.org/wiki/Agile_Modeling Agile] development Technique) and can be used along with modeling languages such as [http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
&lt;br /&gt;
==Software for CRC Cards==&lt;br /&gt;
CRC cards have limited scope. If we go about designing a huge project, the scope spans many classes and interactions between them. The tedious task here is to maintain the CRC cards and properly formulate interaction between them. &lt;br /&gt;
We need software for CRC Cards for the following reasons:&lt;br /&gt;
:* &amp;lt;b&amp;gt;Designing Scenario:&amp;lt;/b&amp;gt;  A scenario represents series of steps in which classes and objects communicate. There can be references to other cards or scenarios. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Modeling :&amp;lt;/b&amp;gt;  Software provides an easy way to segregate cards and objects into different diagrams. Thus we can model our problem with different functionality very easily.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Simulation :&amp;lt;/b&amp;gt; Software can provide simulation of the design. This might include single-stepping a scenario forwards/backwards or jumping to a specific location in the scenario stack of a multiple scenario simulation&lt;br /&gt;
:* &amp;lt;b&amp;gt;Synchronization and Dependencies:&amp;lt;/b&amp;gt; Software can maintain relationships between cards, scenarios as design changes take place. If a card references other cards or classes, those cards are generated automatically. Also any name changes and cross references between objects are instantly updated. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Revision history and Version Control :&amp;lt;/b&amp;gt; Software for CRC cards supports changes to CRC cards. It is easy to model and keep track of all changes to a CRC card. This is extremely helpful in tracking the design changes in CRC cards.&lt;br /&gt;
&lt;br /&gt;
==Designing Software==&lt;br /&gt;
The steps to design software for CRC cards are:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Create CRC Cards&amp;lt;/b&amp;gt; : A CRC model is usually created by an individual or small group of designers during the early phase of an object-oriented development project.The figure shows the design of hierarchy of classes. These set of class used for drawing objects are shown. We can see TShape class has a superclass called TObject and two subclasses, TBox and TCircle. Lets assume we create new class TWindow derived from the superclass TObject.  [[Image:Design.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Assign Responsibilities&amp;lt;/b&amp;gt; : Once a set of classes are defined, behaviors can be assigned that will provide the functions of the application. For example, the TShape card has responsibilities ''Initialize'' to create it and ''Draw'' to illustrate it on the diagram.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Add Attributes&amp;lt;/b&amp;gt; : Attributes of classes may also be identified in a CRC Card.The TShape class has attributes fPosition, fType and fSelected.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Define and simulate Scenario&amp;lt;/b&amp;gt; : A scenario describes a sequence of steps in the design using the responsibilities of a group of collaborating classes. Collaboration between classes refers to a client object that uses a responsibility performed by a server object. Often a class must call upon several collaborating classes to implement one of its responsibilities.A scenario describes what happens in the system from a high-level, user's point of view.&lt;br /&gt;
[[Image:Scenario.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
Consider situation to the right. We have defined two CRC cards with their responsibility. A scenario defines several steps. Each step in a scenario has a Client, Server and Responsibility field. For each step, a client class uses a responsibility of a server class&lt;br /&gt;
&lt;br /&gt;
The Open Document scenario in the picture references the Initialize Document sub-scenario by specifying its server class ''Document'' in the server field and its scenario name in the Responsibility field. The first step in the Initialize Document sub-scenario uses ''Document'' as the server class name. By single-stepping forwards, backwards or through each sub-scenario, bugs in the design can be identified and corrected early.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Partition the Design&amp;lt;/b&amp;gt; : As the number of CRC cards in the design grow, they can be grouped by function. By using Software for CRC cards,we can draw separate diagrams to partition the model into different subject areas. &lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Inheritance Graph&amp;lt;/b&amp;gt; : An automated tool can generate an inheritance graph from information on CRC cards. This diagram can concisely illustrate the big picture of a large project that might contain hundreds of classes and dozens of diagrams.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Verify Your Work &amp;lt;/b&amp;gt; : Creating and simulating scenarios will help verify that a design is correct and complete. A CRC software can perform other error checks to locate design problems. For example, responsibilities that are not used in any scenarios may indicate that the design is incomplete or perhaps the responsibility isn't needed. Likewise, a card that is not used by any collaboration may not be needed.&lt;br /&gt;
&lt;br /&gt;
==Software Development Process for Object Oriented Development==&lt;br /&gt;
&lt;br /&gt;
Software Development Life Cycles are different for a standard development process and for Object Oriented development. This difference needs to be understood in order to know how to meet the benchmarks set for the project. There are multiple processes that are used in software development, the most common ones in use being Waterfall model and Spiral model. The Waterfall model is progression based and the Spiral model is iterative.&lt;br /&gt;
&lt;br /&gt;
We need to understand that the uniqueness of Object Oriented SDLCs comes from the fact that it is more user centric as compared to standard SDLCs that are more system centric. We will now see which models work for Object Oriented SDLCs (OO SDLCs) and which don’t. CRC cards play a very important role in an Object Oriented SDLC. Thus, figuring out which models work well for OO SDLCs will result in understanding which models use CRC cards and why.&lt;br /&gt;
 &lt;br /&gt;
====The Waterfall Model====&lt;br /&gt;
&lt;br /&gt;
The Waterfall model is implemented in multiple phases with each phase having a clear demarcation in terms of its functionality and deliverable. It uses clear stepping stones to come up with deliverables for each deadline. In this case, there are multiple ways to measure progress and methods by which to audit internally and apply checkpoints.&lt;br /&gt;
&lt;br /&gt;
The downside of the Waterfall model lies in the fact that it is a very rigid model that does not offer much in terms of leeway when it comes to deliverables and what each phase in the cycle has to offer. The process is also overly mechanical and over time, just ends up being boring.&lt;br /&gt;
&lt;br /&gt;
Owing to the emphasis on checkpoints and deliverables with strict deadlines, in most cases the analysis and design phases are usually cut short and thus, the project may veer very far from reality. The users are involved only in the requirement gathering phase. This might result in mistranslation of the requirements of the user into what may be an amazing final product but something that the user did not even ask for.&lt;br /&gt;
 &lt;br /&gt;
====The Spiral Model====&lt;br /&gt;
This model iteratively goes through the phases of analysis, design, prototyping and testing after the initial requirements gathering phase. With each iteration, the product is improved based on the feedback from testing in the previous iteration. If required, the outcome of each phase is analyzed, revised and the next prototype is developed after the design is revised, if pertinent. The products from the first phase are not abandoned, they are revised. Evidently, this model is non-linear in nature.&lt;br /&gt;
&lt;br /&gt;
After the first pass through the checkpoint, we can conclude that the work so far is adequate, but not final. The model places emphasis on the iterative process and on the development of standard prototypes at the end of each iteration. At the end of every cycle, we notice the shortcomings from the previous cycle and might end up having to redo all the work in the previous cycle. This proves to be a complete waste of time and effort. All the effort now goes into developing the end point for an older cycle, which makes the model ineffective for the current cycle.&lt;br /&gt;
&lt;br /&gt;
One of the major drawbacks of such a non linear model is that the cost effectiveness and risk analysis cannot be analyzed thoroughly.&lt;br /&gt;
 &lt;br /&gt;
====Why CRC cards are not useful in Waterfall and Spiral Models====&lt;br /&gt;
&lt;br /&gt;
The strength of OO model depends on the idea that, here, design and deployment come together. In the case of a spiral model, this works to make the spiral tighter. Since the waterfall model places over importance on deliverables and user involvement is minimal, which is one of the key focuses of OO SLDCs using CRC cards, the model is considered ineffective. The Spiral model involves multiple revisions of the same idea. When a set of cards have been developed, it would make sense to refine the idea presented in the card but not to redefine them over and over, which may be the case. This does not serve the purpose of actually convening a CRC discussion among the team to draw up cards corresponding to the user requirement. Moreover, in the case of the Spiral model, we would need to convene multiple such meetings at each iteration, which would drastically bring down the overall productivity of the team.&lt;br /&gt;
&lt;br /&gt;
==CRC Cards in Software Development Process==&lt;br /&gt;
&lt;br /&gt;
===Agile Methodology and CRC Cards===&lt;br /&gt;
&lt;br /&gt;
Agile development is a model that has resurfaced and is gaining fame for its incremental cum iterative process. The iteration is carried over the processes of discovery, analysis, design and coding. In each iteration, the old model is worked on in each of the overlapping mini-cycles. The overlap of the cycles makes the process apparently iterative in nature. The model is considered incremental since every step acts as a value-add and this is emphasized by the capacity of classes for reuse. The idea that each phase is repeated ensures that the project is constantly working on a higher level of understanding. Moreover, the OOPS concept of reuse can be used to our advantage such that when we are continuously using OO development models in all our projects, the next implementation can be started  far ahead in the SDLC.&lt;br /&gt;
&lt;br /&gt;
The model focuses on analysis and design phase predominantly. Within each of these are mini phases of analysis-&amp;gt;prototype-&amp;gt;revision-&amp;gt; implementation cycles. The advantage of this model compared to other models described is that, being incremental, this also results in tightening of the spiral at the end of each iteration using concepts such as reusability and polymorphism. Thus, the progression from one point to another in the cycle is seamless from start to deployment.&lt;br /&gt;
&lt;br /&gt;
CRC cards can be very effectively and efficiently used in the Agile model of OO SDLC owing to the fact that it is incremental as well as iterative and not just a repetitive process. Thus, we would not have to redefine the cards from the scratch at any point. Being incremental, we would refine our current model and proceed to refine the entire system as a whole at the end of all iterations. We would essentially be adding value to the cards written out in the previous cycle and if perfected, would never have to discard cards from any of the precious cycles.&lt;br /&gt;
            &lt;br /&gt;
Agile also practices active customer involvement. In every phase, the user is involved. This is one of the key characteristics of the CRC card design method. This not only ensures that the final product is as per the customer's requirements, but also that the customer is thoroughly satisfied, since they are aware of the changes and increments at each level. Another key aspect of Agile methodology is that it is feature driven. A CRC card holds details as to the feature of each class and how it collaborates with the rest of the system. Since this information is readily available to the developer and is highly fine-tuned by the end of the SDLC process, the cards can guarantee focus on 80/20 principle (i.e. pay more attention to 20% of the features which will used 80% of the times). &lt;br /&gt;
&lt;br /&gt;
The power of CRC cards for OOP development is in the group session that employs them.  The use of CRC cards is an excellent way for people to begin to grasp the underlying idea of object oriented approach. CRC cards are used in a few steps of the software development process such as Analysis and Design.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Analysis===&lt;br /&gt;
&lt;br /&gt;
CRC cards and CRC card sessions are good at organizing and spreading domain knowledge in the analysis phase.  When building an object–oriented application, the focus of the CRC card sessions is on analyzing and describing the problem.  In this phase, the group identifies the objects that are relevant to the application.  Before going to the CRC card session, the team must be aware of the domain classes and frameworks that exist to help them model the problem. During the session, they can decide if the existing ones can be used for the new application.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Analysis phase:'''&lt;br /&gt;
&lt;br /&gt;
* People from all phases of the project are involved in the card sessions for problem modeling. The names of the classes and responsibilities are created, argued and agreed upon by the team members at the start itself in order to avoid conflicts later. This gives rise to common project and product vocabulary across different roles.&lt;br /&gt;
&lt;br /&gt;
* Domain knowledge already known is shared in the sessions. Also, missing domain knowledge is identified.&lt;br /&gt;
 &lt;br /&gt;
* Role plays are conducted during these sessions that help spread knowledge about OO concepts.&lt;br /&gt;
&lt;br /&gt;
* These sessions can be used to create a live prototype of what the application is supposed to do. This can be shown to clients as well so that the team receives feedback on their understanding of the requirements.&lt;br /&gt;
 &lt;br /&gt;
* A CRC card session will help the team walk through the requirements and identify any ambiguities.&lt;br /&gt;
&lt;br /&gt;
At the end of the analysis phase, the CRC elements that will be available are:&lt;br /&gt;
&lt;br /&gt;
* '''Classes:''' The classes identified in this phase directly reflect the concepts of the application that is being analyzed. It may not be modeled in terms of software system but it is useful in describing how the application works. However, at this stage the distinction between objects and classes may not be clear.&lt;br /&gt;
&lt;br /&gt;
* '''Responsibilities:'''  The responsibilities that are assigned to the classes in this phase are of relatively higher level.&lt;br /&gt;
&lt;br /&gt;
===CRC Cards for Design===&lt;br /&gt;
 &lt;br /&gt;
During the CRC cards design sessions, other relevant classes are added, if any. &amp;quot;While an analysis must reflect the real world of the user, the design must reflect the real world of the implementers.&amp;quot;[5] A CRC card tool may be helpful for saving, illustrating and documenting a design.&lt;br /&gt;
&lt;br /&gt;
'''Advantages of using CRC cards in Design phase:'''&lt;br /&gt;
&lt;br /&gt;
* These sessions help the team members concentrate on taking the design decisions for the application. These design decisions also include performance, efficiency and other constraints.&lt;br /&gt;
&lt;br /&gt;
* By walking through the scenarios that were seen during the analysis phase, the implementers can give the testers an overview of how the application should work.&lt;br /&gt;
&lt;br /&gt;
* Using CRC cards forces decision to be made up front in front of the team, thus any conflicts can be resolved right there.&lt;br /&gt;
&lt;br /&gt;
* Design constraints such as target environment, language, UI, performance etc., can be discussed during these sessions to check if the design can be implemented.&lt;br /&gt;
&lt;br /&gt;
==Summary==&lt;br /&gt;
Software for CRC cards are immensely helpful in designing and modeling software development using CRC cards.As the size of object-oriented system grow, it becomes increasingly difficult to model the problem with index based CRC cards. Thus an automated tool is required to maintain design and clear functionality.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Agile_Modeling Agile Modelling]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
[1] [http://c2.com/doc/oopsla89/paper.html  A Laboratory For Teaching Object-Oriented Thinking]&lt;br /&gt;
&lt;br /&gt;
[2] [http://www.extremeprogramming.org/rules/crccards.html CRC Cards]&lt;br /&gt;
&lt;br /&gt;
[3] [http://www.extremeprogramming.org/example/crcsim.html A Simulator for Coffee Maker]&lt;br /&gt;
&lt;br /&gt;
[4] [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html CRC Card for ATM]&lt;br /&gt;
&lt;br /&gt;
[5] &amp;quot;Using CRC Cards: An Informal Approach to Object-Oriented Development&amp;quot; by Nancy M.Wilkinson&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html A Laboratory For Teaching Object-Oriented Thinking] by Ward Cunningham and Kent Beck&lt;br /&gt;
* [http://books.google.com/books?id=SGOyQai2TboC&amp;amp;printsec=frontcover&amp;amp;dq=CRC+card+book&amp;amp;hl=en&amp;amp;ei=xSOaTKSaNISclgfRqtkK&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=1&amp;amp;ved=0CDYQ6AEwAA#v=onepage&amp;amp;q&amp;amp;f=false The CRC card book] by David Bellin, Susan Suchman Simone&lt;br /&gt;
&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Modelling CRC Cards]&lt;br /&gt;
* [http://www.excelsoftware.com/quickcrcwin.html Quick CRC]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012&amp;diff=64879</id>
		<title>CSC/ECE 517 Fall 2012</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012&amp;diff=64879"/>
		<updated>2012-09-15T00:03:05Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;*[[CSC/ECE 517 Fall 2012/ch1 n xx]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w1 rk]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w20 pp]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w5 su]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w6 pp]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w7 am]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w8 aa]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w9 av]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w10 pk]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w11 ap]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1a 1w12 mv]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w14 gv]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w17 ir]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w18 as]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w22 an]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w21 aa]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w21 wi]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w31 sa]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1a 1w16 br]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1a 1w23 as]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w24 nr]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w15 rt]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w3 pl]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w32 cm]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w27 ms]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w29 sa]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w33 op]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w19 sa]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2012/ch1 1w34 vd]]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=64877</id>
		<title>CSC/ECE 517 Fall 2012/ch1 1w11 ap</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w11_ap&amp;diff=64877"/>
		<updated>2012-09-15T00:02:11Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: Created page with &amp;quot;==Introduction== &amp;lt;b&amp;gt; CRC Cards &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] ca...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&amp;lt;b&amp;gt; CRC Cards &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] cards are a brainstorming tool to enable collaboration across different teams or individuals in contribution to design, usually used in Object Oriented Software development. This was  proposed by &amp;lt;b&amp;gt;Ward Cunningham&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;Kent Beck&amp;lt;/b&amp;gt;&amp;lt;sup&amp;gt;[http://c2.com/doc/oopsla89/paper.html]&amp;lt;/sup&amp;gt;. The CRC card can be viewed as an index card, with the following details:&lt;br /&gt;
[[Image:crc-card.gif|frame|right|CRC Card Structure]]&lt;br /&gt;
&lt;br /&gt;
:* The Top of the card usually bears the name of the class.&lt;br /&gt;
:* The Left side of the card has the responsibilities of the class.&lt;br /&gt;
:* The Right side of the card has the collaborating classes corresponding to each of the responsibilities listed in the left side.&lt;br /&gt;
&lt;br /&gt;
Thus in general, a CRC session can be viewed as the interaction between a set of collaborating classes for a particular [http://en.wikipedia.org/wiki/Use_case Use case]. &amp;lt;br&amp;gt; &amp;lt;br&amp;gt; According to &amp;lt;sup&amp;gt;[http://www.extremeprogramming.org/rules/crccards.html]&amp;lt;/sup&amp;gt;&amp;lt;i&amp;gt;A CRC session proceeds with someone simulating the system by talking about which objects send messages to other objects. By stepping through the process weaknesses and problems are easily uncovered. Design alternatives can be explored quickly by simulating the design being proposed.&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===A CRC Example===&lt;br /&gt;
To better understand how the CRC cards work together, let us consider a simple student enrollment problem,where we are required to model the students enrolled in different courses. We can easily define the &amp;lt;b&amp;gt;Student CRC Card&amp;lt;/b&amp;gt; as having attributes such as student name, student id and responsibilities that enable a student to enroll in a course or drop the course. In this particular instance, the collaborating class would be the &amp;lt;b&amp;gt;Course&amp;lt;/b&amp;gt; class. The &amp;lt;b&amp;gt;Course CRC Card&amp;lt;/b&amp;gt; can in turn be visualized as having its own responsibilities, such as having attributes like Course Id, course name and the collaborating class would be the &amp;lt;b&amp;gt;Instructor &lt;br /&gt;
class&amp;lt;/b&amp;gt;. The CRC cards for the Student class and the Course Class are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[Image:Stud_enr_Crc.jpg|frame|center|Student and Course CRC Card]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There are also several practical designs that use the CRC card model to design Object oriented software design. The  [http://www.extremeprogramming.org/example/crcsim.html Simulator for Coffee Maker] explores an [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] approach combined with CRC card technique to come up with a design for the coffee maker.&lt;br /&gt;
&lt;br /&gt;
Another interesting approach using CRC cards explores a design for the [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html ATM Machine]&lt;br /&gt;
&lt;br /&gt;
===Advantages of CRC cards===&lt;br /&gt;
There are quite a few advantages of CRC cards that make it a preferable model in many designs. Some of the advantages of the CRC card design method are&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:* CRC cards can allow designers to easily make audience understand a very complex system. In essence it allows for building more complex designs by slowly building the interactions between the collaborating classes, one by one.&lt;br /&gt;
:* CRC cards are a simple technique and it can be easily used by anyone with very little training and does not require any expensive computing resources(a board or a paper and a pen would suffice).&lt;br /&gt;
:* CRC is fundamentally a brainstorming tool, enabling different people in a team to come up with the design by collaborating, enabling everyone in the team to contribute&lt;br /&gt;
:* CRC can be used with other formal object oriented design methodologies such as [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] (an [http://en.wikipedia.org/wiki/Agile_Modeling Agile] development Technique) and can be used along with modelling languages such as [http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
&lt;br /&gt;
==Why need a Software for CRC Cards==&lt;br /&gt;
CRC cards are limited by their scope. If we go about designing a huge project, the scope spans many classes and interactions between them. The tedious task of maintaining are CRC cards and to properly formulate interaction can get overwhelming. &lt;br /&gt;
Following reasons propel use for software for CRC Cards :&lt;br /&gt;
:* &amp;lt;b&amp;gt;Designing Scenario:&amp;lt;/b&amp;gt;  A scenario represents series of steps in which classes and objects communicate. There are be references to other cards or scenarios. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Modeling :&amp;lt;/b&amp;gt;  Software provide an easy way to segregate cards and objects into different diagrams. Thus we can model our software with different functionality very easily.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Simulation :&amp;lt;/b&amp;gt; Software can provides simulation of an software design. This might include single stepping backwards, forwards a scenario or jumping to a specific location in the scenario stack of a multiple scenario simulation&lt;br /&gt;
:* &amp;lt;b&amp;gt;Synchronization and Dependencies:&amp;lt;/b&amp;gt; Software can maintain relationships between cards, scenarios as design changes take place. If a card references other cards or classes, those cards are generated automatically. Also any name changes and cross references between objects are instantly updated. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Revision history and Version Control :&amp;lt;/b&amp;gt; Software for CRC cards supports changes to CRC cards. It is easy to model and keep track of all changes to a CRC cards. This is extremely helpful in realizing the design changes to CRC cards.&lt;br /&gt;
&lt;br /&gt;
==Desining Software==&lt;br /&gt;
The following steps proceed while designing Software for CRC cards:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Create CRC Cards&amp;lt;/b&amp;gt;&lt;br /&gt;
A CRC model is usually created by an individual or small group of designers during the early phase of an object-oriented development project.The figure shows the design of hierarchy of classes. These set of class used for drawing objects are shown. We can see TShape class has a superclass called TObject and two subclasses, TBox and TCircle. Lets assume we create new class TWindow derived from the superclass TObject.  [[Image:Design.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Assign Responsibilities&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once a set of classes are defined, behaviors can be assigned that will provide the functions of the application. For example, the TShape card has responsibilities Initialize to create it and Draw to illustrate it on the diagram.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Add Attributes&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Attributes of classes may also be identified in a CRC Card.The TShape class has attributes fPosition, fType and&lt;br /&gt;
fSelected.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Define and simulate Scenario&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A scenario describes a sequence of steps in the design using the responsibilities of a group of collaborating&lt;br /&gt;
classes. Collaboration between classes refers to a client object that uses a responsibility performed&lt;br /&gt;
by a server object. Often a class must call upon several collaborating classes to implement one of its&lt;br /&gt;
responsibilities.A scenario describes what happens in the system from a high-level, user point of view.&lt;br /&gt;
[[Image:Scenario.png|thumb|Description]]&lt;br /&gt;
Consider situation to the right. We have defined two CRC cards with their responsibility. A scenario deinfes several steps. Each step in a scenario has a Client, Server and Responsibility field. For each step,&lt;br /&gt;
a client class uses a responsibility of a server class&lt;br /&gt;
&lt;br /&gt;
The Open Document scenario in the picture references the Initialize Document subscenario&lt;br /&gt;
by specifying its server class Document in the server field and its scenario name in the Responsibility field.&lt;br /&gt;
The first step in the Initialize Document subscenario uses Document as the server class name.&lt;br /&gt;
&lt;br /&gt;
By single stepping forwards, backwards or through each subscenario, bugs in the design can be identified and corrected early.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Partition the Design&amp;lt;/b&amp;gt;&lt;br /&gt;
As the number of CRC cards in the design grows, they can be grouped by function. Using Software for CRC cards,&lt;br /&gt;
separate diagrams are used to partition the model into different subject areas. &lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Inheritance Graph&amp;lt;/b&amp;gt;&lt;br /&gt;
An automated tool can generate an inheritance graph from information on CRC cards. This diagram can&lt;br /&gt;
concisely illustrate the big picture of a large project that might contain hundreds of classes and dozens of diagrams.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Verify Your Work &amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Creating and simulating scenarios will help verify that a design is correct and complete. A CRC software&lt;br /&gt;
can perform other error checks to locate design problems.&lt;br /&gt;
For example, responsibilities that are not used in any scenarios may indicate that the design is incomplete&lt;br /&gt;
or perhaps the responsibility isn't needed.Likewise, a card that is not used by any collaboration&lt;br /&gt;
may not be needed.&lt;br /&gt;
&lt;br /&gt;
==Summary==&lt;br /&gt;
Software for CRC cards are immensely helpful in designing and modeling Software development using CRC cards.As the size of object-oriented system grow, it becomes increasingly difficult to model the problem with index based CRC cards. Thus an automated tool is required to maintain design and clear functionality.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Agile_Modeling Agile Modelling]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
[1] A Laboratory For Teaching Object-Oriented Thinking: [http://c2.com/doc/oopsla89/paper.html http://c2.com/doc/oopsla89/paper.html]&lt;br /&gt;
&lt;br /&gt;
[2] CRC Cards: [http://www.extremeprogramming.org/rules/crccards.html http://www.extremeprogramming.org/rules/crccards.html]&lt;br /&gt;
&lt;br /&gt;
[3] [http://www.extremeprogramming.org/example/crcsim.html A Simulator for Coffee Maker]&lt;br /&gt;
&lt;br /&gt;
[4] [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html CRC Card for ATM]&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html A Laboratory For Teaching Object-Oriented Thinking] by Ward Cunningham and Kent Beck&lt;br /&gt;
* [http://books.google.com/books?id=SGOyQai2TboC&amp;amp;printsec=frontcover&amp;amp;dq=CRC+card+book&amp;amp;hl=en&amp;amp;ei=xSOaTKSaNISclgfRqtkK&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=1&amp;amp;ved=0CDYQ6AEwAA#v=onepage&amp;amp;q&amp;amp;f=false The CRC card book] by David Bellin, Susan Suchman Simone&lt;br /&gt;
&lt;br /&gt;
* [http://books.google.com/books?id=baopCOstm_kC&amp;amp;pg=PA29&amp;amp;lpg=PA29&amp;amp;dq=creating+software+for+CRC+cards&amp;amp;source=bl&amp;amp;ots=hABGQbbmXV&amp;amp;sig=CTHPtCN1GmZEyTAIPWvKE--8-M4&amp;amp;hl=en&amp;amp;ei=7ReaTISDKYL68Aadtq08&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=9&amp;amp;ved=0CEsQ6AEwCDgK#v=onepage&amp;amp;q&amp;amp;f=false Using CRC Cards: An Informal Approach to Object-Oriented Development]&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Modelling CRC Cards]&lt;br /&gt;
* [http://www.excelsoftware.com/quickcrcwin.html Quick CRC]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w19_sa&amp;diff=64745</id>
		<title>CSC/ECE 517 Fall 2012/ch1 1w19 sa</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2012/ch1_1w19_sa&amp;diff=64745"/>
		<updated>2012-09-14T23:22:05Z</updated>

		<summary type="html">&lt;p&gt;Asridha2: Created page with &amp;quot;==Introduction== &amp;lt;b&amp;gt; CRC Cards &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] ca...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Introduction==&lt;br /&gt;
&amp;lt;b&amp;gt; CRC Cards &amp;lt;/b&amp;gt; also known as [http://en.wikipedia.org/wiki/Class-responsibility-collaboration_card &amp;lt;b&amp;gt; Class-Responsibility-Collaboration &amp;lt;sup&amp;gt;&amp;lt;/sup&amp;gt;&amp;lt;/b&amp;gt;] cards are a brainstorming tool to enable collaboration across different teams or individuals in contribution to design, usually used in Object Oriented Software development. This was  proposed by &amp;lt;b&amp;gt;Ward Cunningham&amp;lt;/b&amp;gt; and &amp;lt;b&amp;gt;Kent Beck&amp;lt;/b&amp;gt;&amp;lt;sup&amp;gt;[http://c2.com/doc/oopsla89/paper.html]&amp;lt;/sup&amp;gt;. The CRC card can be viewed as an index card, with the following details:&lt;br /&gt;
[[Image:crc-card.gif|frame|right|CRC Card Structure]]&lt;br /&gt;
&lt;br /&gt;
:* The Top of the card usually bears the name of the class.&lt;br /&gt;
:* The Left side of the card has the responsibilities of the class.&lt;br /&gt;
:* The Right side of the card has the collaborating classes corresponding to each of the responsibilities listed in the left side.&lt;br /&gt;
&lt;br /&gt;
Thus in general, a CRC session can be viewed as the interaction between a set of collaborating classes for a particular [http://en.wikipedia.org/wiki/Use_case Use case]. &amp;lt;br&amp;gt; &amp;lt;br&amp;gt; According to &amp;lt;sup&amp;gt;[http://www.extremeprogramming.org/rules/crccards.html]&amp;lt;/sup&amp;gt;&amp;lt;i&amp;gt;A CRC session proceeds with someone simulating the system by talking about which objects send messages to other objects. By stepping through the process weaknesses and problems are easily uncovered. Design alternatives can be explored quickly by simulating the design being proposed.&amp;lt;/i&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===A CRC Example===&lt;br /&gt;
To better understand how the CRC cards work together, let us consider a simple student enrollment problem,where we are required to model the students enrolled in different courses. We can easily define the &amp;lt;b&amp;gt;Student CRC Card&amp;lt;/b&amp;gt; as having attributes such as student name, student id and responsibilities that enable a student to enroll in a course or drop the course. In this particular instance, the collaborating class would be the &amp;lt;b&amp;gt;Course&amp;lt;/b&amp;gt; class. The &amp;lt;b&amp;gt;Course CRC Card&amp;lt;/b&amp;gt; can in turn be visualized as having its own responsibilities, such as having attributes like Course Id, course name and the collaborating class would be the &amp;lt;b&amp;gt;Instructor &lt;br /&gt;
class&amp;lt;/b&amp;gt;. The CRC cards for the Student class and the Course Class are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[Image:Stud_enr_Crc.jpg|frame|center|Student and Course CRC Card]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There are also several practical designs that use the CRC card model to design Object oriented software design. The  [http://www.extremeprogramming.org/example/crcsim.html Simulator for Coffee Maker] explores an [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] approach combined with CRC card technique to come up with a design for the coffee maker.&lt;br /&gt;
&lt;br /&gt;
Another interesting approach using CRC cards explores a design for the [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html ATM Machine]&lt;br /&gt;
&lt;br /&gt;
===Advantages of CRC cards===&lt;br /&gt;
There are quite a few advantages of CRC cards that make it a preferable model in many designs. Some of the advantages of the CRC card design method are&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:* CRC cards can allow designers to easily make audience understand a very complex system. In essence it allows for building more complex designs by slowly building the interactions between the collaborating classes, one by one.&lt;br /&gt;
:* CRC cards are a simple technique and it can be easily used by anyone with very little training and does not require any expensive computing resources(a board or a paper and a pen would suffice).&lt;br /&gt;
:* CRC is fundamentally a brainstorming tool, enabling different people in a team to come up with the design by collaborating, enabling everyone in the team to contribute&lt;br /&gt;
:* CRC can be used with other formal object oriented design methodologies such as [http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming] (an [http://en.wikipedia.org/wiki/Agile_Modeling Agile] development Technique) and can be used along with modelling languages such as [http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
&lt;br /&gt;
==Why need a Software for CRC Cards==&lt;br /&gt;
CRC cards are limited by their scope. If we go about designing a huge project, the scope spans many classes and interactions between them. The tedious task of maintaining are CRC cards and to properly formulate interaction can get overwhelming. &lt;br /&gt;
Following reasons propel use for software for CRC Cards :&lt;br /&gt;
:* &amp;lt;b&amp;gt;Designing Scenario:&amp;lt;/b&amp;gt;  A scenario represents series of steps in which classes and objects communicate. There are be references to other cards or scenarios. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Modeling :&amp;lt;/b&amp;gt;  Software provide an easy way to segregate cards and objects into different diagrams. Thus we can model our software with different functionality very easily.&lt;br /&gt;
:* &amp;lt;b&amp;gt;Simulation :&amp;lt;/b&amp;gt; Software can provides simulation of an software design. This might include single stepping backwards, forwards a scenario or jumping to a specific location in the scenario stack of a multiple scenario simulation&lt;br /&gt;
:* &amp;lt;b&amp;gt;Synchronization and Dependencies:&amp;lt;/b&amp;gt; Software can maintain relationships between cards, scenarios as design changes take place. If a card references other cards or classes, those cards are generated automatically. Also any name changes and cross references between objects are instantly updated. &lt;br /&gt;
:* &amp;lt;b&amp;gt;Revision history and Version Control :&amp;lt;/b&amp;gt; Software for CRC cards supports changes to CRC cards. It is easy to model and keep track of all changes to a CRC cards. This is extremely helpful in realizing the design changes to CRC cards.&lt;br /&gt;
&lt;br /&gt;
==Desining Software==&lt;br /&gt;
The following steps proceed while designing Software for CRC cards:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Create CRC Cards&amp;lt;/b&amp;gt;&lt;br /&gt;
A CRC model is usually created by an individual or small group of designers during the early phase of an object-oriented development project.The figure shows the design of hierarchy of classes. These set of class used for drawing objects are shown. We can see TShape class has a superclass called TObject and two subclasses, TBox and TCircle. Lets assume we create new class TWindow derived from the superclass TObject.  [[Image:Design.png|thumb|Description]]&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Assign Responsibilities&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once a set of classes are defined, behaviors can be assigned that will provide the functions of the application. For example, the TShape card has responsibilities Initialize to create it and Draw to illustrate it on the diagram.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Add Attributes&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Attributes of classes may also be identified in a CRC Card.The TShape class has attributes fPosition, fType and&lt;br /&gt;
fSelected.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Define and simulate Scenario&amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A scenario describes a sequence of steps in the design using the responsibilities of a group of collaborating&lt;br /&gt;
classes. Collaboration between classes refers to a client object that uses a responsibility performed&lt;br /&gt;
by a server object. Often a class must call upon several collaborating classes to implement one of its&lt;br /&gt;
responsibilities.A scenario describes what happens in the system from a high-level, user point of view.&lt;br /&gt;
[[Image:Scenario.png|thumb|Description]]&lt;br /&gt;
Consider situation to the right. We have defined two CRC cards with their responsibility. A scenario deinfes several steps. Each step in a scenario has a Client, Server and Responsibility field. For each step,&lt;br /&gt;
a client class uses a responsibility of a server class&lt;br /&gt;
&lt;br /&gt;
The Open Document scenario in the picture references the Initialize Document subscenario&lt;br /&gt;
by specifying its server class Document in the server field and its scenario name in the Responsibility field.&lt;br /&gt;
The first step in the Initialize Document subscenario uses Document as the server class name.&lt;br /&gt;
&lt;br /&gt;
By single stepping forwards, backwards or through each subscenario, bugs in the design can be identified and corrected early.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Partition the Design&amp;lt;/b&amp;gt;&lt;br /&gt;
As the number of CRC cards in the design grows, they can be grouped by function. Using Software for CRC cards,&lt;br /&gt;
separate diagrams are used to partition the model into different subject areas. &lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Inheritance Graph&amp;lt;/b&amp;gt;&lt;br /&gt;
An automated tool can generate an inheritance graph from information on CRC cards. This diagram can&lt;br /&gt;
concisely illustrate the big picture of a large project that might contain hundreds of classes and dozens of diagrams.&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;b&amp;gt;Verify Your Work &amp;lt;/b&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Creating and simulating scenarios will help verify that a design is correct and complete. A CRC software&lt;br /&gt;
can perform other error checks to locate design problems.&lt;br /&gt;
For example, responsibilities that are not used in any scenarios may indicate that the design is incomplete&lt;br /&gt;
or perhaps the responsibility isn't needed.Likewise, a card that is not used by any collaboration&lt;br /&gt;
may not be needed.&lt;br /&gt;
&lt;br /&gt;
==Summary==&lt;br /&gt;
Software for CRC cards are immensely helpful in designing and modeling Software development using CRC cards.As the size of object-oriented system grow, it becomes increasingly difficult to model the problem with index based CRC cards. Thus an automated tool is required to maintain design and clear functionality.&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Unified_Modeling_Language Unified Modeling Language(UML)]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Agile_Modeling Agile Modelling]&lt;br /&gt;
*[http://en.wikipedia.org/wiki/Extreme_Programming Extreme Programming]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
[1] A Laboratory For Teaching Object-Oriented Thinking: [http://c2.com/doc/oopsla89/paper.html http://c2.com/doc/oopsla89/paper.html]&lt;br /&gt;
&lt;br /&gt;
[2] CRC Cards: [http://www.extremeprogramming.org/rules/crccards.html http://www.extremeprogramming.org/rules/crccards.html]&lt;br /&gt;
&lt;br /&gt;
[3] [http://www.extremeprogramming.org/example/crcsim.html A Simulator for Coffee Maker]&lt;br /&gt;
&lt;br /&gt;
[4] [http://www.math-cs.gordon.edu/courses/cps211/ATMExample/CRCCards.html CRC Card for ATM]&lt;br /&gt;
&lt;br /&gt;
==External Links==&lt;br /&gt;
* [http://c2.com/doc/oopsla89/paper.html A Laboratory For Teaching Object-Oriented Thinking] by Ward Cunningham and Kent Beck&lt;br /&gt;
* [http://books.google.com/books?id=SGOyQai2TboC&amp;amp;printsec=frontcover&amp;amp;dq=CRC+card+book&amp;amp;hl=en&amp;amp;ei=xSOaTKSaNISclgfRqtkK&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=1&amp;amp;ved=0CDYQ6AEwAA#v=onepage&amp;amp;q&amp;amp;f=false The CRC card book] by David Bellin, Susan Suchman Simone&lt;br /&gt;
&lt;br /&gt;
* [http://books.google.com/books?id=baopCOstm_kC&amp;amp;pg=PA29&amp;amp;lpg=PA29&amp;amp;dq=creating+software+for+CRC+cards&amp;amp;source=bl&amp;amp;ots=hABGQbbmXV&amp;amp;sig=CTHPtCN1GmZEyTAIPWvKE--8-M4&amp;amp;hl=en&amp;amp;ei=7ReaTISDKYL68Aadtq08&amp;amp;sa=X&amp;amp;oi=book_result&amp;amp;ct=result&amp;amp;resnum=9&amp;amp;ved=0CEsQ6AEwCDgK#v=onepage&amp;amp;q&amp;amp;f=false Using CRC Cards: An Informal Approach to Object-Oriented Development]&lt;br /&gt;
* [http://www.agilemodeling.com/artifacts/crcModel.htm Modelling CRC Cards]&lt;br /&gt;
* [http://www.excelsoftware.com/quickcrcwin.html Quick CRC]&lt;/div&gt;</summary>
		<author><name>Asridha2</name></author>
	</entry>
</feed>