mirror of
https://github.com/grassrootseconomics/cic-chain-events.git
synced 2024-11-22 07:46:46 +01:00
refactor: move filter and fetch to pkg
This commit is contained in:
parent
f791b87172
commit
02e31146cc
@ -1 +0,0 @@
|
||||
export TEST_GRAPHQL_ENDPOINT=
|
5
Makefile
5
Makefile
@ -13,6 +13,5 @@ mod:
|
||||
go mod tidy
|
||||
go mod verify
|
||||
|
||||
test:
|
||||
source .env.test
|
||||
go test -v -covermode atomic -coverprofile=covprofile ./internal/...
|
||||
test-pkg:
|
||||
TEST_GRAPHQL_ENDPOINT=https://rpc.alfajores.celo.grassecon.net/graphql go test -v -covermode atomic -coverprofile=covprofile ./pkg/...
|
@ -1,7 +1,7 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/filter"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/filter"
|
||||
)
|
||||
|
||||
func initAddressFilter() filter.Filter {
|
||||
|
@ -5,9 +5,9 @@ import (
|
||||
"strings"
|
||||
|
||||
"github.com/alitto/pond"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/pool"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/store"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
"github.com/jackc/pgx/v5"
|
||||
"github.com/knadh/goyesql/v2"
|
||||
"github.com/knadh/koanf"
|
||||
|
@ -11,9 +11,9 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/api"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/filter"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/pipeline"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/syncer"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/filter"
|
||||
"github.com/knadh/goyesql/v2"
|
||||
"github.com/knadh/koanf"
|
||||
"github.com/zerodha/logf"
|
||||
|
@ -3,9 +3,9 @@ package pipeline
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/filter"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/store"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/filter"
|
||||
"github.com/jackc/pgx/v5"
|
||||
"github.com/zerodha/logf"
|
||||
)
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"sync"
|
||||
|
||||
celo "github.com/grassrootseconomics/cic-celo-sdk"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
"github.com/zerodha/logf"
|
||||
)
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"sync"
|
||||
"testing"
|
||||
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
"github.com/stretchr/testify/suite"
|
||||
"github.com/zerodha/logf"
|
||||
)
|
@ -5,7 +5,7 @@ import (
|
||||
"math/big"
|
||||
|
||||
"github.com/celo-org/celo-blockchain/common"
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
"github.com/grassrootseconomics/w3-celo-patch"
|
||||
"github.com/zerodha/logf"
|
||||
)
|
@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"testing"
|
||||
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
"github.com/stretchr/testify/suite"
|
||||
"github.com/zerodha/logf"
|
||||
)
|
@ -3,7 +3,7 @@ package filter
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/grassrootseconomics/cic-chain-events/internal/fetch"
|
||||
"github.com/grassrootseconomics/cic-chain-events/pkg/fetch"
|
||||
)
|
||||
|
||||
// Filter defines a read only filter which must return next as true/false or an error
|
Loading…
Reference in New Issue
Block a user