Comparison

spec/util_pubsub_spec.lua @ 10434:8f709577fe8e

Merge 0.11->trunk
author Kim Alvefur <zash@zash.se>
date Sat, 23 Nov 2019 23:12:01 +0100
parent 10356:0a2d7efca039
child 10541:6c6ff4509082
comparison
equal deleted inserted replaced
10433:7777f25d5266 10434:8f709577fe8e
105 end); 105 end);
106 106
107 it("fails to publish to a node with differing config", function () 107 it("fails to publish to a node with differing config", function ()
108 local ok, err = service:publish("node", true, "1", "item 2", { myoption = false }); 108 local ok, err = service:publish("node", true, "1", "item 2", { myoption = false });
109 assert.falsy(ok); 109 assert.falsy(ok);
110 assert.equals("precondition-not-met", err); 110 assert.equals("precondition-not-met", err.pubsub_condition);
111 end); 111 end);
112 112
113 it("allows to publish to a node with differing config when only defaults are suggested", function () 113 it("allows to publish to a node with differing config when only defaults are suggested", function ()
114 assert(service:publish("node", true, "1", "item 2", { _defaults_only = true, myoption = false })); 114 assert(service:publish("node", true, "1", "item 2", { _defaults_only = true, myoption = false }));
115 end); 115 end);