Skip to content

Commit

Permalink
fix spec/01-unit/01-db/10-declarative_spec.lua
Browse files Browse the repository at this point in the history
  • Loading branch information
chronolaw committed Oct 21, 2024
1 parent f5423a4 commit eada306
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions spec/01-unit/01-db/10-declarative_spec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@ keyauth_credentials:
it("utilizes the schema name, workspace id, field name, and checksum of the field value", function()
local key = unique_field_key("services", "123", "fieldname", "test", false)
assert.is_string(key)
assert.equals("services|123|fieldname|" .. sha256_hex("test"), key)
assert.equals("services|fieldname|123|" .. sha256_hex("test"), key)
end)

-- since incremental sync the param `unique_across_ws` is useless
-- this test case is just for compatibility
it("does not omits the workspace id when 'unique_across_ws' is 'true'", function()
local key = unique_field_key("services", "123", "fieldname", "test", true)
assert.equals("services|123|fieldname|" .. sha256_hex("test"), key)
assert.equals("services|fieldname|123|" .. sha256_hex("test"), key)
end)
end)

Expand Down

0 comments on commit eada306

Please sign in to comment.