What about MCP23S17 GPIO pins output ports being also used to be read by input pins?
They are not different than many MCU GPIO pins. Unfortunately the datasheet has no block diagram at all to explain this.

The pins have direction control register to set the pin direction between input and output. Basically it just controls if the output buffer is enabled or disabled.

When output buffer is enabled, the pin is a push-pull output which drives the pin state high or low according to the output data register. When the output buffer is disabled, it is in high-z state, so it can act as an input pin, so another device can drive the pin.

The current state of the pin can always be read from the input register, whether it is an input or output.

There is also a pull-up enable register, which can enable an internal pull-up for a pin, to set it's state high if nothing else is connected. This removes the need for external pull-up resistors.

And finally, as the pin is completely under user control, it can be set to be either low output or high-z state, to emulate an open-drain IO pin.

1) Yes, you can connect one pin to another, and write the output pin and read input pin to see if they are connected together or not.

2) No, nothing special is needed. Just one input and one output is enough.

Open-drain can be used too, but you don't have to.