Skip to content

Commit 3861469

Browse files
committed
ajustes para funcionar o jest
1 parent f6163d6 commit 3861469

File tree

5 files changed

+238
-295
lines changed

5 files changed

+238
-295
lines changed

app.js

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,4 +224,16 @@ document.addEventListener('DOMContentLoaded', function() {
224224
document.querySelectorAll('input[name="moon-view"]').forEach(radio => {
225225
radio.addEventListener('change', generateMoonPhases);
226226
});
227-
});
227+
});
228+
229+
// Exports para testes Node.js (Jest)
230+
if (typeof module !== 'undefined' && module.exports) {
231+
module.exports = {
232+
calculateDifference,
233+
daysSince,
234+
generateCalendar,
235+
calculateAge,
236+
formatDate,
237+
generateMoonPhases
238+
};
239+
}

0 commit comments

Comments
 (0)