summaryrefslogtreecommitdiff
path: root/core/string_name.h
diff options
context:
space:
mode:
authorRevoluPowered <gordon@gordonite.tech>2020-07-20 17:35:34 +0100
committerGordon MacPherson <gordon@gordonite.tech>2020-07-24 13:05:33 +0100
commit579342810f5c453e91063c54ca6544300ea09090 (patch)
treeb01e1478605b835e1fe903384d753b114106d51e /core/string_name.h
parent93b50a62e333cd05702fb749ebcdc18127abe01b (diff)
t Add unit testing to Godot using DocTest and added to GitHub Actions CI
Implements exit codes into the engine so tests can return their statuses. Ideally we don't do this, and we use FIXUP logic to 'begin' and 'end' the engine execution for tests specifically. Since realistically we're initialising the engine here we don't want to do that, since String should not require an engine startup to test a single header. This lowers the complexity of running the unit tests and even for physics should be possible to implement such a fix.
Diffstat (limited to 'core/string_name.h')
-rw-r--r--core/string_name.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/string_name.h b/core/string_name.h
index df6b458581..886ddd0ee7 100644
--- a/core/string_name.h
+++ b/core/string_name.h
@@ -35,6 +35,8 @@
#include "core/safe_refcount.h"
#include "core/ustring.h"
+class Main;
+
struct StaticCString {
const char *ptr;
static StaticCString create(const char *p_ptr);
@@ -73,7 +75,7 @@ class StringName {
void unref();
friend void register_core_types();
friend void unregister_core_types();
-
+ friend class Main;
static Mutex mutex;
static void setup();
static void cleanup();