@@ -5,14 +5,15 @@ import (
55 "testing"
66 "time"
77
8- billingv1 "github.com/appuio/control-api/apis/billing/v1"
9- "github.com/appuio/control-api/apiserver/billing/odoostorage/odoo/odoo8/client"
10- "github.com/appuio/control-api/apiserver/billing/odoostorage/odoo/odoo8/client/clientmock"
11- "github.com/appuio/control-api/apiserver/billing/odoostorage/odoo/odoo8/client/model"
128 "github.com/golang/mock/gomock"
139 "github.com/stretchr/testify/assert"
1410 "github.com/stretchr/testify/require"
1511 metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
12+
13+ billingv1 "github.com/appuio/control-api/apis/billing/v1"
14+ "github.com/appuio/control-api/apiserver/billing/odoostorage/odoo/odoo8/client"
15+ "github.com/appuio/control-api/apiserver/billing/odoostorage/odoo/odoo8/client/clientmock"
16+ "github.com/appuio/control-api/apiserver/billing/odoostorage/odoo/odoo8/client/model"
1617)
1718
1819func TestGet (t * testing.T ) {
@@ -46,9 +47,12 @@ func TestGet(t *testing.T) {
4647 ObjectMeta : metav1.ObjectMeta {
4748 Name : "be-456" ,
4849 CreationTimestamp : metav1.Time {Time : tn },
50+ Annotations : map [string ]string {
51+ VSHNAccountingContactNameKey : "Accounting" ,
52+ },
4953 },
5054 Spec : billingv1.BillingEntitySpec {
51- Name : "Test Company, Accounting " ,
55+ Name : "Test Company" ,
5256 Emails : []string {},
5357 AccountingContact : billingv1.BillingEntityContact {
5458 Emails : []string {
@@ -157,9 +161,12 @@ func TestList(t *testing.T) {
157161 {
158162 ObjectMeta : metav1.ObjectMeta {
159163 Name : "be-456" ,
164+ Annotations : map [string ]string {
165+ VSHNAccountingContactNameKey : "Accounting" ,
166+ },
160167 },
161168 Spec : billingv1.BillingEntitySpec {
162- Name : "Test Company, Accounting " ,
169+ Name : "Test Company" ,
163170 Emails : []string {},
164171 AccountingContact : billingv1.BillingEntityContact {
165172 Emails : []string {},
@@ -168,9 +175,12 @@ func TestList(t *testing.T) {
168175 }, {
169176 ObjectMeta : metav1.ObjectMeta {
170177 Name : "be-457" ,
178+ Annotations : map [string ]string {
179+ VSHNAccountingContactNameKey : "Accounting" ,
180+ },
171181 },
172182 Spec : billingv1.BillingEntitySpec {
173- Name : "Foo Company, Accounting " ,
183+ Name : "Foo Company" ,
174184 Emails : []string {},
175185 AccountingContact : billingv1.BillingEntityContact {
176186 Emails : []string {},
0 commit comments