Skip to content

Commit

Permalink
Rebranding tests folder
Browse files Browse the repository at this point in the history
  • Loading branch information
ArrowsFlying committed Oct 17, 2024
1 parent 0dc3957 commit 9641cdf
Show file tree
Hide file tree
Showing 15 changed files with 68 additions and 68 deletions.
10 changes: 5 additions & 5 deletions tests/core/io/test_config_file.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ TEST_CASE("[ConfigFile] Parsing well-formatted files") {
name = "Unnamed Player"
tagline="Waiting
for
Godot"
Blazium"
color =Color( 0, 0.5,1, 1) ; Inline comment
position= Vector2(
Expand All @@ -68,7 +68,7 @@ antiAliasing = false
String(config_file.get_value("player", "name")) == "Unnamed Player",
"Reading `player/name` should return the expected value.");
CHECK_MESSAGE(
String(config_file.get_value("player", "tagline")) == "Waiting\nfor\nGodot",
String(config_file.get_value("player", "tagline")) == "Waiting\nfor\nBlazium",
"Reading `player/tagline` should return the expected value.");
CHECK_MESSAGE(
Color(config_file.get_value("player", "color")).is_equal_approx(Color(0, 0.5, 1)),
Expand Down Expand Up @@ -96,7 +96,7 @@ TEST_CASE("[ConfigFile] Parsing malformatted file") {
[player]
name = "Unnamed Player"" ; Extraneous closing quote.
tagline = "Waiting\nfor\nGodot"
tagline = "Waiting\nfor\nBlazium"
color = Color(0, 0.5, 1) ; Missing 4th parameter.
position = Vector2(
Expand All @@ -118,7 +118,7 @@ antialiasing = false ; Duplicate key.
TEST_CASE("[ConfigFile] Saving file") {
ConfigFile config_file;
config_file.set_value("player", "name", "Unnamed Player");
config_file.set_value("player", "tagline", "Waiting\nfor\nGodot");
config_file.set_value("player", "tagline", "Waiting\nfor\nBlazium");
config_file.set_value("player", "color", Color(0, 0.5, 1));
config_file.set_value("player", "position", Vector2(3, 4));
config_file.set_value("graphics", "antialiasing", true);
Expand All @@ -140,7 +140,7 @@ TEST_CASE("[ConfigFile] Saving file") {
name="Unnamed Player"
tagline="Waiting
for
Godot"
Blazium"
color=Color(0, 0.5, 1, 1)
position=Vector2(3, 4)
Expand Down
4 changes: 2 additions & 2 deletions tests/core/io/test_json.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,11 @@ TEST_CASE("[JSON] Parsing arrays") {
TEST_CASE("[JSON] Parsing objects (dictionaries)") {
JSON json;

json.parse(R"({"name": "Godot Engine", "is_free": true, "bugs": null, "apples": {"red": 500, "green": 0, "blue": -20}, "empty_object": {}})");
json.parse(R"({"name": "Blazium Engine", "is_free": true, "bugs": null, "apples": {"red": 500, "green": 0, "blue": -20}, "empty_object": {}})");

const Dictionary dictionary = json.get_data();
CHECK_MESSAGE(
dictionary["name"] == "Godot Engine",
dictionary["name"] == "Blazium Engine",
"The parsed JSON should contain the expected values.");
CHECK_MESSAGE(
dictionary["is_free"],
Expand Down
2 changes: 1 addition & 1 deletion tests/core/io/test_marshalls.h
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ TEST_CASE("[Marshalls] Floating point double precision decoding") {
}

TEST_CASE("[Marshalls] C string encoding") {
char cstring[] = "Godot"; // 5 characters
char cstring[] = "Blazium"; // 5 characters
uint8_t data[6];

int actual_size = encode_cstring(cstring, data);
Expand Down
2 changes: 1 addition & 1 deletion tests/core/math/test_quaternion.h
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ TEST_CASE("[Quaternion] Product") {

// Test ZYX dynamic-axes since test data is available online.
// Rotate first about X axis, then new Y axis, then new Z axis.
// (Godot uses YXZ Yaw-Pitch-Roll order).
// (Blazium uses YXZ Yaw-Pitch-Roll order).
Quaternion q_yp = q_y * q_p;
CHECK(q_yp[0] == doctest::Approx(0.239118));
CHECK(q_yp[1] == doctest::Approx(0.369644));
Expand Down
4 changes: 2 additions & 2 deletions tests/core/os/test_os.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ TEST_CASE("[OS] Execute") {
const Error err = OS::get_singleton()->execute("cmd", arguments, nullptr, &exit_code);
CHECK_MESSAGE(
err == OK,
"(Running the command `cmd /C \"dir > NUL\"` returns the expected Godot error code (OK).");
"(Running the command `cmd /C \"dir > NUL\"` returns the expected Blazium error code (OK).");
CHECK_MESSAGE(
exit_code == 0,
"Running the command `cmd /C \"dir > NUL\"` returns a zero (successful) exit code.");
Expand All @@ -194,7 +194,7 @@ TEST_CASE("[OS] Execute") {
const Error err = OS::get_singleton()->execute("sh", arguments, nullptr, &exit_code);
CHECK_MESSAGE(
err == OK,
"(Running the command `sh -c \"ls > /dev/null\"` returns the expected Godot error code (OK).");
"(Running the command `sh -c \"ls > /dev/null\"` returns the expected Blazium error code (OK).");
CHECK_MESSAGE(
exit_code == 0,
"Running the command `sh -c \"ls > /dev/null\"` returns a zero (successful) exit code.");
Expand Down
30 changes: 15 additions & 15 deletions tests/core/string/test_string.h
Original file line number Diff line number Diff line change
Expand Up @@ -285,9 +285,9 @@ TEST_CASE("[String] Testing for empty string") {
}

TEST_CASE("[String] Contains") {
String s = "C:\\Godot\\project\\string_test.tscn";
String s = "C:\\Blazium\\project\\string_test.tscn";
CHECK(s.contains(":\\"));
CHECK(s.contains("Godot"));
CHECK(s.contains("Blazium"));
CHECK(s.contains(String("project\\string_test")));
CHECK(s.contains(String("\\string_test.tscn")));

Expand All @@ -298,9 +298,9 @@ TEST_CASE("[String] Contains") {
}

TEST_CASE("[String] Contains case insensitive") {
String s = "C:\\Godot\\project\\string_test.tscn";
CHECK(s.containsn("Godot"));
CHECK(s.containsn("godot"));
String s = "C:\\Blazium\\project\\string_test.tscn";
CHECK(s.containsn("Blazium"));
CHECK(s.containsn("Blazium"));
CHECK(s.containsn(String("Project\\string_test")));
CHECK(s.containsn(String("\\string_Test.tscn")));

Expand Down Expand Up @@ -1409,7 +1409,7 @@ TEST_CASE("[String] Checking string is empty when it should be") {
if (!success) {
state = false;
}
String b = "Godot";
String b = "Blazium";
success = b[b.size()] == 0;
if (!success) {
state = false;
Expand All @@ -1420,7 +1420,7 @@ TEST_CASE("[String] Checking string is empty when it should be") {
state = false;
}

const String d = "Godot";
const String d = "Blazium";
success = d[d.size()] == 0;
if (!success) {
state = false;
Expand Down Expand Up @@ -1546,7 +1546,7 @@ TEST_CASE("[String] Count and countn functionality") {
s = "TestTestTest";
MULTICHECK_STRING_EQ(s, count, "TestTest", 1);

s = "TestGodotTestGodotTestGodot";
s = "TestBlaziumTestBlaziumTestBlazium";
MULTICHECK_STRING_EQ(s, count, "Test", 3);

s = "TestTestTestTest";
Expand Down Expand Up @@ -1615,12 +1615,12 @@ TEST_CASE("[String] dedent") {
}

TEST_CASE("[String] Path functions") {
static const char *path[8] = { "C:\\Godot\\project\\test.tscn", "/Godot/project/test.xscn", "../Godot/project/test.scn", "Godot\\test.doc", "C:\\test.", "res://test", "user://test", "/.test" };
static const char *base_dir[8] = { "C:\\Godot\\project", "/Godot/project", "../Godot/project", "Godot", "C:\\", "res://", "user://", "/" };
static const char *base_name[8] = { "C:\\Godot\\project\\test", "/Godot/project/test", "../Godot/project/test", "Godot\\test", "C:\\test", "res://test", "user://test", "/" };
static const char *path[8] = { "C:\\Blazium\\project\\test.tscn", "/Blazium/project/test.xscn", "../Blazium/project/test.scn", "Blazium\\test.doc", "C:\\test.", "res://test", "user://test", "/.test" };
static const char *base_dir[8] = { "C:\\Blazium\\project", "/Blazium/project", "../Blazium/project", "Blazium", "C:\\", "res://", "user://", "/" };
static const char *base_name[8] = { "C:\\Blazium\\project\\test", "/Blazium/project/test", "../Blazium/project/test", "Blazium\\test", "C:\\test", "res://test", "user://test", "/" };
static const char *ext[8] = { "tscn", "xscn", "scn", "doc", "", "", "", "test" };
static const char *file[8] = { "test.tscn", "test.xscn", "test.scn", "test.doc", "test.", "test", "test", ".test" };
static const char *simplified[8] = { "C:/Godot/project/test.tscn", "/Godot/project/test.xscn", "Godot/project/test.scn", "Godot/test.doc", "C:/test.", "res://test", "user://test", "/.test" };
static const char *simplified[8] = { "C:/Blazium/project/test.tscn", "/Blazium/project/test.xscn", "Blazium/project/test.scn", "Blazium/test.doc", "C:/test.", "res://test", "user://test", "/.test" };
static const bool abs[8] = { true, true, false, false, true, true, true, true };

for (int i = 0; i < 8; i++) {
Expand Down Expand Up @@ -1653,8 +1653,8 @@ TEST_CASE("[String] hash") {
}

TEST_CASE("[String] uri_encode/unescape") {
String s = "Godot Engine:'docs'";
String t = "Godot%20Engine%3A%27docs%27";
String s = "Blazium Engine:'docs'";
String t = "Blazium%20Engine%3A%27docs%27";

String x1 = "T%C4%93%C5%A1t";
static const uint8_t u8str[] = { 0x54, 0xC4, 0x93, 0xC5, 0xA1, 0x74, 0x00 };
Expand Down Expand Up @@ -1781,7 +1781,7 @@ TEST_CASE("[String] Reverse") {
}

TEST_CASE("[String] SHA1/SHA256/MD5") {
String s = "Godot";
String s = "Blazium";
String sha1 = "a1e91f39b9fce6a9998b14bdbe2aa2b39dc2d201";
static uint8_t sha1_buf[20] = {
0xA1, 0xE9, 0x1F, 0x39, 0xB9, 0xFC, 0xE6, 0xA9, 0x99, 0x8B, 0x14, 0xBD, 0xBE, 0x2A, 0xA2, 0xB3,
Expand Down
12 changes: 6 additions & 6 deletions tests/core/templates/test_list.h
Original file line number Diff line number Diff line change
Expand Up @@ -441,15 +441,15 @@ TEST_CASE("[List] Swap middle (values check)") {
List<String>::Element *n_str1 = list.push_back("Still");
List<String>::Element *n_str2 = list.push_back("waiting");
List<String>::Element *n_str3 = list.push_back("for");
List<String>::Element *n_str4 = list.push_back("Godot.");
List<String>::Element *n_str4 = list.push_back("Blazium.");

CHECK(n_str1->get() == "Still");
CHECK(n_str4->get() == "Godot.");
CHECK(n_str4->get() == "Blazium.");

CHECK(list.front()->get() == "Still");
CHECK(list.front()->next()->get() == "waiting");
CHECK(list.back()->prev()->get() == "for");
CHECK(list.back()->get() == "Godot.");
CHECK(list.back()->get() == "Blazium.");

list.swap(n_str2, n_str3);

Expand All @@ -459,18 +459,18 @@ TEST_CASE("[List] Swap middle (values check)") {

TEST_CASE("[List] Swap front and back (values check)") {
List<Variant> list;
Variant str = "Godot";
Variant str = "Blazium";
List<Variant>::Element *n_str = list.push_back(str);
Variant color = Color(0, 0, 1);
List<Variant>::Element *n_color = list.push_back(color);

CHECK(list.front()->get() == "Godot");
CHECK(list.front()->get() == "Blazium");
CHECK(list.back()->get() == Color(0, 0, 1));

list.swap(n_str, n_color);

CHECK(list.front()->get() == Color(0, 0, 1));
CHECK(list.back()->get() == "Godot");
CHECK(list.back()->get() == "Blazium");
}

TEST_CASE("[List] Swap adjacent back and front (reverse order of elements)") {
Expand Down
Loading

0 comments on commit 9641cdf

Please sign in to comment.