-
Notifications
You must be signed in to change notification settings - Fork 2
/
format_test.go
56 lines (45 loc) · 1.35 KB
/
format_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
package gonut
import (
"encoding/hex"
"testing"
)
func TestFormatTemplate_ToBase64(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(300))
t.Logf("\n%s\n", tpl.ToBase64())
}
func TestFormatTemplate_ToBinary(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(300))
t.Logf("\n%s\n", hex.Dump(tpl.ToBinary()))
}
func TestFormatTemplate_ToCSharp(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(276))
t.Logf("\n%s\n", tpl.ToCSharp())
}
func TestFormatTemplate_ToHex(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(300))
t.Logf("\n%s\n", tpl.ToHex())
}
func TestFormatTemplate_ToPowerShell(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(33))
t.Logf("\n%s\n", tpl.ToPowerShell())
}
func TestFormatTemplate_ToPython(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(300))
t.Logf("\n%s\n", tpl.ToPython())
}
func TestFormatTemplate_ToRubyC(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(280))
t.Logf("\n%s\n", tpl.ToRubyC())
}
func TestFormatTemplate_ToGolang(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(277))
t.Logf("\n%s\n", tpl.ToGolang())
}
func TestFormatTemplate_ToRust(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(277))
t.Logf("\n%s\n", tpl.ToRust())
}
func TestFormatTemplate_ToUUID(t *testing.T) {
tpl := NewFormatTemplate(GenRandomBytes(277))
t.Logf("\n%s\n", tpl.ToUUID())
}