Giter VIP home page Giter VIP logo

videoworldnet's Introduction

Frameworks

NUNit
https://launchpad.net/nunitv2

Mock testing library : Moq
http://code.google.com/p/moq/

ASP.NET MVC version 3

http://www.asp.net/mvc/tutorials/creating-unit-tests-for-asp-net-mvc-applications-vb

UI testing

http://www.specflow.org/
http://smnbss.wordpress.com/2010/11/02/unveil-the-power-of-bdd-with-specflow-and-selenium-part-1/

h2 Selenium v2 (Webdriver)

We use selenium for testing the app. This can be kind of slow if you use Firefox or IE.

You can use HtmlUnit via the RemoteDriver by uncommenting the appropriate code in SeleniumSupport.cs.
Note that for this to work the selenium remote driver must be running. This is checked into the lib/test
directory. You can run it by doing:

java -jar lib\test\selenium-server-standalone-2.0b2.jar

Notes on the Code

Code smells

These are code smells that we might want to discuss with the participants

Prices

  • The IPrice.GetCharge method could be given a more descriptive name
  • The unit tests for the IPrice implementations only cover “normal” cases (no edge cases)
  • There are no tests for the frequent renter points in IPrice
h3. Movie
  • Movie has a price, as well as a get and set property
  • Movie allows a null price

Take a look at MovieTests, there is a Law of Demeter violation :

Assert.AreEqual(1, RegularMovieInstance.Price.GetFrequentRenterPoints(1));

This chould be refactored to look like this:

Assert.AreEqual(1, RegularMovieInstance.GetFrequentRenterPoints(1));

videoworldnet's People

Contributors

persiannose avatar saleem avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.