If two beds are the only two things to fit into a small house and there is a door then when two players go to bed they will both wake up in the doorway and the hitboxes of both players will overlap. Neither player will be able to use a bed, break blocks, or open the door until one of the two players is killed or teleports.
To recreate build a tiny house with only 4 blocks of empty space:
X = Dirt Wall
E = Door
1 = first bed, 2 = second bed
Top:
XXXX
X12X
X12X
XXEX
Player 1 sleep in 1. Then player 2 enter, close door, and sleep in 2.
Come morning both players will be standing inside door at E and be unable to do anything until death or teleportation.