In this paper, we demonstrate the importance of the details of the equilibria on the stability of electron drift waves. A comparison of electrostatic electron drift waves in numerical and analytical tokamak equilibria is presented in fully three-dimensional circular and non-circular tokamaks. The numerical equilibria are obtained using the variational moments equilibrium code and the analytical equilibria used is the generalizedŝ-α model. An eigenvalue equation for the model is derived using the ballooning mode formalism and solved numerically using a standard shooting technique. The stability and the localization of the electron drift wave is found to be strongly dependent on the local shear of the magnetic field. Large values of the local shear are found to be stabilizing. A disagreement in the results is found between analytical and numerical equilibria at aspect ratios of typical tokamaks, suggesting that the latter approach should be used in the transport calculations. The effects of the local shaping of the magnetic surfaces are complicated and can be both stabilizing and destabilizing, depending on the details of the equilibria.