Here's a simple test you can give candidates. 

 

You can download the same project here: DotNetTest.zip (13.94 kb)

.Net Test

Purpose: Evaluate candidate’s familiarity with OO Design and implementation.

 

Database

 

  1. Create a table in the database (connection string in Web.Config) Called Emails
    1. Emails table should have 4 columns. First column is called ID it’s a primary key with identity insert turned on.
    2. Other three columns should be called Email, Name, HasError has error should be of type bit.
  2. Put the SQL create table script into the App_Data folder
  3. Create a stored procedure that accepts three parameters Email,Name,HasError
  4. Using dynamic SQL within the stored procedure insert the record into the database.

 

Business Logic

 

  1. Implement ASM.Web.Business.Emailer.Insert should iterate through collection inserting records into the database via stored procedure implemented in Data section.
  2. Implement ASM.Web.Common.Email both shared Sub. This logic should email and call Emailer.Insert.

 

User Interface

  1. Create a web form.
  2. Put two text boxes on the page. One called Email the other name.
  3. Place two buttons on the page once called “Send Once” the other “Send 5 Times”
  4. Using javascript create validation that forces the user to enter text into both fields and alerts the user to enter in text use this when someone clicks on either buttons.
  5. Add a Custom Validator control to ensure the user enters a valid email address.
  6. When you click the Send Once button it should implement ASM.Web.Common.SendEmail using Business.Email Class
  7. When you click the Send 5 Times email it should implement the ASM.Web.Common.SendEmail using the Business.EmailCollection Class

 

Result:

 

When you click the Send Once button it send one email and insert one record into the Emails table.

 

When you click the Send 5 Times button it should send 5 emails and insert 5 records into the Emails table.