You could be referring to two different things.
1) This is an example of an intermediate belief. Cognitions can be thought of as three levels: automatic thoughts (which are the first thoughts that pop into our heads), intermediate beliefs (which often take the form of rules, attitudes, and assumptions), and core beliefs (which reflect our deepest levels of thought and core values).
An example is:
- Situation: Not understanding part of a lecture
- Automatic thought: I'll never learn this! I'm an idiot! Why bother trying?
Intermediate beliefs: (which can take the form of should or must statements)
*Attitude: Failing at anything is terrible
*Assumption: If I challenge myself, I'm sure to fail. If I do things that come easily, I'll succeed.
*Rule: If I can't do this easily, I should just give up.
Core belief: I'm incompetent
2) The statements you mention are also examples of dysfunctional thoughts (also called cognitive distortions), specifically all-or-nothing thinking (seeing things in black or white) or "imperatives" (should or must statements).
These errors in thinking are our tendency to draw invalid conclusions or selectively pay attention to evidence to support our thinking.
Example of all-or-nothing thinking: If I don't get a 100% on the test, I'm a failure. If she doesn't return my phone call immediately, she hates me. (That second example is also a bit of jumping to conclusions).
Example of imperatives: Making any mistake is terrible; I should always do my best. If I ask for help, I am weak; I must be completely self-reliant.
Search these terms for more information: Intermediate beliefs, dysfunctional thoughts, cognitive distortions
Reference:
Beck, J.S. (2011). Cognitive Behavior Therapy. 2nd Edition. New York, NY: The Guilford Press.