Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 794591
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T22:20:16+00:00 2026-05-14T22:20:16+00:00

I am learning MVC and I understand the basics now. It is very good

  • 0

I am learning MVC and I understand the basics now. It is very good for CRUD pages and has built in HTTP methods to post/get edits/updates. That is nice. This is all very testable by just creating a new controller and testing it.

But I was thinking about other web page scenerios when using MVC. What about a page that has 2 listboxes that you add/remove users with. (A button will move the user from one listbox to another)

This would be done using Jquery/Javascript… But then what happens to testing? How do you test adding/removing users from a listbox like that example?

It seems to me the more jquery you use the less testable the page becomes right? When you get beyond basic forms being filled out then you need to use something more than the standard MVC pages.

What is the correct philosophy on this on when am I not understanding ?

  • 1 1 Answer
  • 3 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T22:20:16+00:00Added an answer on May 14, 2026 at 10:20 pm
    1. adding/removing users can’t be done with jQuery alone, unless your users database is local to the client browser. at some point you will have to invoke a controller action in the MVC application to persist the choice. that action is unit testable.
    2. there are fameworks and techniques for unit testing JavaScript that you can use to unit test your jQery code.

    The right way to think about this scenario is to separate your application into two – one server MVC app and a client side jQuery app. The fact that the client-side code is generated and delivered by the server side app actions and views is irrelevant.

    Once you start separating these two, you can start thinking about how to unit test each of them properly.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Just I am learning MVC,(ofcourse i get enough information from MS Website).I want to
I am learning ASP.NET MVC now a days and I have found that most
I'm learning iPhone/iPad programming. I believe I understand the concept of MVC; what I'm
I am learning MVVM now and I understand few things (more than but few
I am learning MVC 3 from asp.net site. My MVC 3 application already has
I am learning MVC and I need to understand why it doesn't work the
I am learning ASP.NET MVC and I like it. However, I am very confused
I'm learning MVC and trying to follow some tutorials and this video http://channel9.msdn.com/Events/DevDays/DevDays-2011-Netherlands/Devdays002 In
I'm trying to understand MVC, and learning CI framework. I've some questions about MVC
I am learning MVC 3 after hours right now and last night I ran

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.