Skip to content

Commit acbbe26

Browse files
authored
Merge pull request #22 from EmbarkStudios/webbju/as-datatypes-unit-test
Angelscript datatypes unit-test.
2 parents 5d9352c + 8f2ecef commit acbbe26

File tree

2 files changed

+54
-0
lines changed

2 files changed

+54
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
class UDatatypesTest
2+
{
3+
void Test()
4+
{
5+
int A = 0;
6+
int8 B = 0;
7+
int16 C = 0;
8+
int32 D = 0;
9+
int64 E = 0;
10+
uint F = 0;
11+
uint8 G = 0;
12+
uint16 H = 0;
13+
uint32 I = 0;
14+
uint64 J = 0;
15+
float K = 0.0f;
16+
float32 L = 0.0f;
17+
float64 M = 0.0;
18+
double N = 0.0;
19+
bool O = true;
20+
21+
// https://angelscript.hazelight.se/scripting/fname-literals/
22+
FName P = n"MyName";
23+
24+
// https://angelscript.hazelight.se/scripting/format-strings/
25+
check(true, f"Formatted String: {L:0.1f}\u00B0");
26+
}
27+
};
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
class UDatatypesTest
2+
{
3+
void Test()
4+
{
5+
int A = 0;
6+
int8 B = 0;
7+
int16 C = 0;
8+
int32 D = 0;
9+
int64 E = 0;
10+
uint F = 0;
11+
uint8 G = 0;
12+
uint16 H = 0;
13+
uint32 I = 0;
14+
uint64 J = 0;
15+
float K = 0.0f;
16+
float32 L = 0.0f;
17+
float64 M = 0.0;
18+
double N = 0.0;
19+
bool O = true;
20+
21+
// https://angelscript.hazelight.se/scripting/fname-literals/
22+
FName P = n"MyName";
23+
24+
// https://angelscript.hazelight.se/scripting/format-strings/
25+
check(true, f"Formatted String: {L:0.1f}\u00B0");
26+
}
27+
};

0 commit comments

Comments
 (0)