12345678910111213141516171819202122232425262728293031 |
- package micro
- import (
- "reflect"
- "testing"
- )
- func TestReporter_getMachineCode(t *testing.T) {
- type fields struct {
- ServerAddr string
- machineCode []byte
- }
- tests := []struct {
- name string
- fields fields
- want []byte
- }{
- // TODO: Add test cases.
- }
- for _, tt := range tests {
- t.Run(tt.name, func(t *testing.T) {
- r := &Reporter{
- ServerAddr: tt.fields.ServerAddr,
- machineCode: tt.fields.machineCode,
- }
- if got := r.getMachineCode(); !reflect.DeepEqual(got, tt.want) {
- t.Errorf("Reporter.getMachineCode() = %v, want %v", got, tt.want)
- }
- })
- }
- }
|