Thanks Tom
Maybe the following could work, it seems to do what you want when I try
it here.
(progn
(let ((default-directory "path1"))
(eshell t)
(rename-buffer "b1"))
(let ((default-directory "path2"))
(eshell t)
(rename-buffer "b2")))
(progn
(eshell t)
(eshell/cd "path1")
(eshell-send-input)
(eshell t)
(eshell/cd "path2")
(eshell-send-input))
Hope it helps in some small way.