mirror of
https://github.com/tomasriveral/NoteWrapper.git
synced 2026-10-10 08:55:22 +02:00
Test: add github actions
This commit is contained in:
1 parent
a142f92c79
commit
2a5b08b737
2 files changed
+45
No files matched your search
@@ -23,3 +23,17 @@ run: $(TARGET)
|
||||
|
||||
clean:
|
||||
rm -f $(TARGET)
|
||||
|
||||
test: $(TARGET)
|
||||
@timeout 5s ./$(TARGET); \
|
||||
status=$$?; \
|
||||
if [ $$status -eq 124 ]; then \
|
||||
echo "Program ran for 5 seconds without crashing ✅"; \
|
||||
exit 0; \
|
||||
elif [ $$status -ne 0 ]; then \
|
||||
echo "Program crashed ❌"; \
|
||||
exit 1; \
|
||||
else \
|
||||
echo "Program exited cleanly ✅"; \
|
||||
exit 0; \
|
||||
fi
|
||||
Reference in new issue
Block a user