In order to contribute to the understanding of runaway electron generation mechanisms during tokamak disruptions, a test particle tracker is introduced in the JOREK 3D non-linear MHD code, able to compute both full and guiding center relativistic orbits. Tests of the module show good conservation of the invariants of motion and consistency between full orbit and guiding center solutions. A first application is presented where test electron confinement properties are investigated in a massive gas injection-triggered disruption simulation in JET-like geometry. It is found that electron populations initialised before the thermal quench (TQ) are typically not fully deconfined in spite of the global stochasticity of the magnetic field during the TQ. The fraction of 'survivors' decreases from a few tens down to a few tenths of percent as the electron energy varies from 1 keV to 10 MeV. The underlying mechanism for electron 'survival' is the prompt reformation of closed magnetic surfaces at the plasma core and, to a smaller extent, the subsequent reappearance of a magnetic surface at the edge. It is also found that electrons are less deconfined at 10 MeV than at 1 MeV, which appears consistent with a phase averaging effect due to orbit shifts at high energy.