Refactor Node tests