According to STP theory and conversations in this forum STP can detect physical loop between two Ethernet Interfaces on the same switch.
Just additional question.
Does Spanning Tree Protocol detect, if physical loop condition exists on single switch Ethernet Interface (Tx pair wires connected with Rx pair wires)?
Will the STP protocol put this port into Blocked State ?
Yes it does. This has been laborious on the standard side, but Cisco switches have always (or at least for a long time) been able to do this. It was particularly useful because of cabling adapted to token ring, that used to loop back the interface should the connector be unplugged. Some switch display a special state of "looped back" for this blocking condition.