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

  • SEARCH
  • Home
  • 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 8010527
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T18:45:41+00:00 2026-06-04T18:45:41+00:00

Is it possible to run a unit test case after user has entered the

  • 0

Is it possible to run a unit test case after user has entered the values in the GUI Screen.Lets consider I have a NSTextFiled.I have written a test case to check the value of the textField.So I was running the test case from product->Test,My Screen is getting loaded and suddenly disappearing.Can I hold the screen and enter the values into the textfield and then test the value of textfield.Is it possible?

  • 1 1 Answer
  • 0 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-06-04T18:45:44+00:00Added an answer on June 4, 2026 at 6:45 pm

    Reading input from the user before running tests defeats the purpose of unit testing. Unit tests are meant to run automatically without requiring user input.

    In your case you are trying to test what happens when the user enters a certain value in a text field. Suppose you write a test for what happens when the user enters 50 in the text field. Instead of inputting 50 in the text field, supply the value 50 in your test. By supplying the value 50 you can unit test your code without requiring user input.

    You should also take a look at OCMock, which is a framework for creating mock objects in Objective-C. OCMock makes unit testing with Cocoa objects easier.

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

Sidebar

Related Questions

Is it possible to write and run with Visual Studio 2008 some unit test
I'm trying to run a GUI unit test with DUnit to an application whose
I have a Groovy unit test class that has many unit tests. In the
Is it possible to instruct maven-surefire-plugin to run just one unit test? And of
Possible Duplicate: How do you generate dynamic (parameterized) unit tests in Python? I have
I have 1 unit test method that needs several parameters. I would like to
I have a solution with two service projects (one is hosting a unit test
Possible Duplicate: How should I unit test threaded code? The classical unit testing is
I would like to unit test a method on a class I have made,
I have a long-running unit test job in hudson. If some tests fail I

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.