Are you a candidate looking to sharpen your skills? Try our practice tests or view sample interview questions & Get hired by the best. Click Here×

Skills Test on TDD (Test Driven Development)

Topics Covered

  • Unit Tests
  • Fakes
  • UI testing
  • TestSetUp and TearDown
  • Assertion
  • Basics
  • Verification
  • Returning Mocks
  • Method Mocking
  • Interface Mocking
  • Expectations

Useful for hiring

  • Software Test Engineer - Test Driven Development
  • Senior Full Stack Engineer
  • Software Development Engineer
  • Senior C# Developer

Start hiring job-fit candidates using this assessment

GET A DEMO

"The best part of Interview Mocha is they have topic wise questions available. The skill wise extensive reports and advanced analytics lets us measure & benchmark the proficiency level of employees in that particular skill."

Cheryl Tolkinen, Securian, USA,
Learning & Development Manager
Question

Suppose you have a class A and a method B that you want to mock using the Moq framework. Under which of the following conditions can you mock A and B?

Answer
    • Class A must be sealed and method B must be marked virtual.

    • Class A must not be sealed and method B must be marked virtual.

    • Class A must not be sealed and method B must be marked static.

    • Class A must be sealed and method B must be marked static.

Question

You have mocked an interface containing an integer variable, say varIt, and named the mock object as mockInterface. Which of the following statements make mockInterface return "Accepted" string if varIt is an integer between 0 and 10 (both included)?

Answer
    • mockedInterface.Expect(a => a.Get(It.IsAny<int>(varIt => between[0,10]))).Returns("Accepted");

    • mockedInterface.Expect(a => a.Get(It.Any<value>(varIt => from[0,10]))).Returns("Accepted");

    • mockedInterface.Expect(a => a.Get(It.Is<int>(varIt => varIt>0 && varIt<10))).Returns("Accepted");

    • mockedInterface.Expect(a => a.Get(Int.IsAny(varIt =>from[0] to [10]))).Returns("Accepted");

Question

In order to mock the interface shown below, which of the following options must be used?    

public interface eStore
{
     List Select();
     eProduct Get(int id);
 }

Answer
    • Mock Interface option in the Mock tab in Visual Studio.

    • MockInterface productStore = new MockInterface<eStore>();

    • Mock pane in the Tools tab of Visual Studio.

    • var productStore = new Mock<eStore>();

Test details:

Identify potential hires by evaluating working skills and job readiness using our valid & reliable assessment test on TDD (Test Driven Development).

The test contains MCQ's (Multiple Choice Questions), MAQ's (Multiple Answer Questions), Fill in the Blank, Descriptive, True or False.
 
Test Details: 20 minutes
 
10 Application Questions
 
This test contains the combination of application and theory questions on TDD with Microsoft Unit test framework & TDD with MOQ (Mocking) that helps you to evaluate technical as well as practical skills of candidates.

Test description:

The Skills Test on Test Driven Development (TDD) in C# has been designed and developed to help hiring managers & recruiters to evaluate the TDD skills of candidates for C# before hiring or recruiting.

Test Driven Development (TDD) is a process which relies on a very short repetition development cycle. It is a type of programming where coding, testing, and designing are intertwined for the process.

TDD online test is created & validated by global subject matter experts to assess & hire C# developers with excellent skills in TDD.

Online TDD test (for C#) contains questions on following Topics:
 

  • Unit Tests

  • Fakes

  • UI testing

  • TestSetUp and TearDown

  • Assertion

  • Basics

  • Verification

  • Returning Mocks

  • Method Mocking

  • Interface Mocking

  • Expectations


Powerful reports will be generated instantly. It gives you the detailed hiring analytics of Test Driven Development (TDD) pre-employment test that helps in analyzing the technical skills related strengths & weaknesses of the candidates.

Good News! You can customize this test as per your requirement

  • Choose and add questions from Interview Mocha question libraries

  • Add your own set of questions

  • Customize test settings like duration, number of questions, passing score, web proctoring and much more

  • Mail us at support@interviewmocha.com to create a custom test

Looking for a tailor-made test, to suit your assessment needs?

Get in touch

Global companies using Mocha assessments

  • altran
  • credit suisse
  • sephora
  • nielsen
  • capgemini
  • akamai

How Mocha assessments are brewed

Speed up your IT recruitment with Interview Mocha

  • 500+ IT skill tests
  • 20+ coding languages
  • 50+ domain knowledge tests
  • 100+ digital 2.0 skill tests
  • Customer focus aptitude tests
  • Enterprise ready features & more...
GET A DEMO

Why hiring managers and recruiters across the globe love Interview Mocha

Take your first step to hire job fit candidates

GET A DEMO