Skip to content

Commit

Permalink
Merge pull request #1 from jehiah/test_updates_1
Browse files Browse the repository at this point in the history
Update test harness
  • Loading branch information
jehiah authored Sep 30, 2021
2 parents 24e213b + 50f7c04 commit 52b7f9c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ jobs:
- "golang:1.17-bullseye"
goarch:
- "amd64"
- "386"

container: "${{matrix.imgtag}}"
env:
Expand All @@ -30,7 +29,6 @@ jobs:

- name: build
run: |
apt-get install build-essential
cd $SRCDIR
make all
- name: test
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Little Bigtable

![CI Status](https://github.com/bitly/little_bigtable/actions/workflows/test.yaml/badge.svg?branch=master)

A local emulator for [Cloud Bigtable](https://cloud.google.com/bigtable) with persistance to a sqlite3 backend.

The Cloud SDK provided `cbtemulator` is in-memory and does not support persistance which limits it's applicability. This project is a fork of `cbtemulator` from [google-cloud-go/bigtable/bttest](https://github.com/googleapis/google-cloud-go/tree/c46c1c395b5f2fb89776a2d0e478e39a2d5572e4/bigtable/bttest)
Expand Down
2 changes: 1 addition & 1 deletion bttest/inmem_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ func SampleRowKeysConcurrentTest(t *testing.T, antagonist AntagonistFunction) {
finished <- true
}()
go antagonist(s, attempts, tbl.Name, finished)
timeout := time.After(10 * time.Second)
timeout := time.After(15 * time.Second)
for i := 0; i < 2; i++ {
select {
case <-finished:
Expand Down
10 changes: 7 additions & 3 deletions bttest/sql_tables.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,15 @@ func (t *table) Scan(src interface{}) error {
}

b := bytes.NewBuffer(src.([]byte))
return gob.NewDecoder(b).Decode(&t.families)
err := gob.NewDecoder(b).Decode(&t.families)

// TODO: set to max
t.counter = uint64(len(t.families))
return nil
for _, f := range t.families {
if f.Order > t.counter {
t.counter = f.Order
}
}
return err
}

func (t *table) Bytes() ([]byte, error) {
Expand Down

0 comments on commit 52b7f9c

Please sign in to comment.