This is an aikido technique that has its roots in jujutsu. Aikido comes from a synthisis of many different styles of jutsu, both armed and unarmed. As a result, you will find some form of weapons training and familiarization in most aikido dojo.
Just like any instance of combat with an armed opponent, these sword techniques would never be easy to execute on the battlefield. The samurai were still taught these skills to give them a small chance of success should they lose their weapon, or some other factor were to present itself to allow them that fighting chance.
In reality, however, the chances for success in a situation like this would have been very slim, but not altogether impossible.
Still, in aikido, we practice, train, and study these movements on both sides. That is to say we study the movements of the attacker (uke, teki, uchidachi) and the movements of the defender (nage, ware, shidachi).