add create and delete namespace to runtime (#1965)

* add create and delete namespace to runtime

* dial down aggressive expiry

* add logging

* fix deletenamespace

* add start of k8s unit tests

* fix workflow

* turn on k8s tests

* ease tight tests

* mkdir in workflow

* dammit -p

* setup folder
This commit is contained in:
Dominic Wong
2020-08-24 16:54:39 +01:00
committed by GitHub
parent 0adb469a85
commit 5a52b5929c
7 changed files with 215 additions and 8 deletions

View File

@@ -339,7 +339,7 @@ func suffixPrefixExpiryTests(s store.Store, t *testing.T) {
&store.Record{
Key: "foobar",
Value: []byte("foobarfoobar"),
Expiry: time.Millisecond * 100,
Expiry: 1 * time.Second,
},
}
@@ -358,7 +358,7 @@ func suffixPrefixExpiryTests(s store.Store, t *testing.T) {
}
// wait for the expiry
time.Sleep(time.Millisecond * 200)
time.Sleep(1 * time.Second)
if results, err := s.Read("foo", store.ReadPrefix()); err != nil {
t.Errorf("Couldn't read all \"foo\" keys, got %# v (%s)", spew.Sdump(results), err)
@@ -388,12 +388,12 @@ func suffixPrefixExpiryTests(s store.Store, t *testing.T) {
Key: "barfoo",
Value: []byte("barfoobarfoo"),
Expiry: time.Millisecond * 100,
Expiry: time.Second * 1,
},
&store.Record{
Key: "bazbarfoo",
Value: []byte("bazbarfoobazbarfoo"),
Expiry: 2 * time.Millisecond * 100,
Expiry: 2 * time.Second,
},
}
for _, r := range records {
@@ -410,7 +410,7 @@ func suffixPrefixExpiryTests(s store.Store, t *testing.T) {
}
}
time.Sleep(time.Millisecond * 100)
time.Sleep(time.Second * 1)
if results, err := s.Read("foo", store.ReadSuffix()); err != nil {
t.Errorf("Couldn't read all \"foo\" keys, got %# v (%s)", spew.Sdump(results), err)
} else {
@@ -420,7 +420,7 @@ func suffixPrefixExpiryTests(s store.Store, t *testing.T) {
}
}
time.Sleep(time.Millisecond * 100)
time.Sleep(time.Second * 1)
if results, err := s.Read("foo", store.ReadSuffix()); err != nil {
t.Errorf("Couldn't read all \"foo\" keys, got %# v (%s)", spew.Sdump(results), err)
} else {