2019-07-28 17:20:24 +02:00
|
|
|
import os
|
|
|
|
import time as t
|
|
|
|
import crypto.sha256 as s2
|
|
|
|
import (
|
|
|
|
math
|
|
|
|
log as l
|
|
|
|
crypto.sha512 as s5
|
|
|
|
)
|
|
|
|
|
2020-01-23 21:07:53 +01:00
|
|
|
struct TestAliasInStruct {
|
|
|
|
time t.Time
|
|
|
|
}
|
|
|
|
|
2019-09-22 08:48:15 +02:00
|
|
|
fn test_import() {
|
2020-01-23 21:07:53 +01:00
|
|
|
assert os.O_RDONLY == os.O_RDONLY && t.month_days[0] == t.month_days[0] && s2.size == s2.size && math.pi == math.pi && l.INFO == l.INFO && s5.size == s5.size
|
|
|
|
}
|
|
|
|
|
|
|
|
fn test_alias_in_struct_field() {
|
|
|
|
a := TestAliasInStruct{
|
|
|
|
time: t.Time{
|
|
|
|
year: 2020
|
|
|
|
}
|
|
|
|
}
|
|
|
|
assert a.time.year == 2020
|
2019-07-28 17:20:24 +02:00
|
|
|
}
|