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 684387
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T01:48:40+00:00 2026-05-14T01:48:40+00:00

A lot of code in a current project is directly related to displaying things

  • 0

A lot of code in a current project is directly related to displaying things using a 3rd-party 3D rendering engine. As such, it’s easy to say “this is a special case, you can’t unit test it”. But I wonder if this is a valid excuse… it’s easy to think “I am special” but rarely actually the case.

Are there types of code which are genuinely not suited for unit-testing? By suitable, I mean “without it taking longer to figure out how to write the test than is worth the effort”… dealing with a ton of 3D math/rendering it could take a lot of work to prove the output of a function is correct compared with just looking at the rendered graphics.

  • 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-05-14T01:48:41+00:00Added an answer on May 14, 2026 at 1:48 am

    Code that directly relates to displaying information, generating images and even general UI stuff, is sometimes hard to unit-test.

    However that mostly applies only to the very top level of that code. Usually 1-2 method calls below the “surface” is code that’s easily unit tested.

    For example, it may be nontrivial to test that some information is correctly animated into the dialog box when a validation fails. However, it’s very easy to check if the validation would fail for any given input.

    Make sure to structure your code in a way that the “non-testable” surface area is well-separated from the test and write extensive tests for the non-surface code.

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

Sidebar

Related Questions

I have a current existing project repository that has a lot of code that
I am using Code Igniter for my current project. As of now, I am
In my current project I see a lot of this type of code: public
I need to write & manage a lot of JavaScript code for current project.
In my project I have a lot of code like this: int[][] a =
I'm working on a project that is using code from an OpenSource project. One
So we've been running a daily build on our current project for a lot
For my current project, I am using parallax scrolling on the website, and am
Working on a maintenance project, I am struggling with lot of messy code. In
On my current project we set ourselves some goals for the code metrics Maintainability

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.