aboutsummaryrefslogtreecommitdiff
path: root/tests/Object.m
diff options
context:
space:
mode:
authorArslaan Pathan <[email protected]>2026-10-02 19:08:12 +1300
committerArslaan Pathan <[email protected]>2026-10-02 19:08:12 +1300
commitce421c6d05c7855ce50d0377362096f258335d4c (patch)
treeafada9f9d2fffc536bb7fa2667b71d9747f3a45b /tests/Object.m
parent68bc96f76ad2de4077bc2a9916f4facbefe5f739 (diff)
downloadParadox-ce421c6d05c7855ce50d0377362096f258335d4c.tar.xz
Paradox-ce421c6d05c7855ce50d0377362096f258335d4c.zip
Debugging stuff and basic PXObject test
Diffstat (limited to 'tests/Object.m')
-rw-r--r--tests/Object.m26
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/Object.m b/tests/Object.m
new file mode 100644
index 0000000..be81b1d
--- /dev/null
+++ b/tests/Object.m
@@ -0,0 +1,26 @@
+#include <Paradox/Core.h>
+#include <stdio.h>
+
+int main(void) {
+ printf("PXObject test\n");
+
+ PXObject *object = [PXObject allocDebug];
+
+ if (object == nil) {
+ fprintf(stderr, "PXObject failed to alloc :c\n");
+ return 1;
+ }
+
+ object = [object init];
+
+ if (object == nil) {
+ fprintf(stderr, "PXObject failed to init :c\n");
+ return 1;
+ }
+
+ [object dealloc];
+
+ printf("If you got this far without segfaulting or crashing it means it allocated and initialized a PXObject, then deallocated it. Yayayayayay\n");
+
+ return 0;
+}