You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
783 B

  1. //go:build dameng
  2. // +build dameng
  3. package dameng
  4. import (
  5. "testing"
  6. "github.com/seaweedfs/seaweedfs/weed/filer/store_test"
  7. )
  8. func TestStore(t *testing.T) {
  9. // run "make test_ydb" under docker folder.
  10. // to set up local env
  11. store := &DamengStore{}
  12. store.initialize("localhost", `MERGE INTO %s AS target
  13. USING (SELECT ? AS dirhash, ? AS name, ? AS directory, ? AS meta FROM dual) AS source
  14. ON (target.dirhash = source.dirhash AND target.name = source.name)
  15. WHEN MATCHED THEN
  16. UPDATE SET target.meta = source.meta
  17. WHEN NOT MATCHED THEN
  18. INSERT (dirhash, name, directory, meta)
  19. VALUES (source.dirhash, source.name, source.directory, source.meta);`,
  20. true, "SYSDBA", "SYSDBA001", "localhost", 5236,
  21. "seaweedfs", 100, 2, 10, false)
  22. store_test.TestFilerStore(t, store)
  23. }