revert test changes

This commit is contained in:
fryorcraken 2025-07-19 19:21:39 +10:00
parent e53717cd08
commit 97a26b2373
No known key found for this signature in database
GPG Key ID: A82ED75A8DFC50A4

View File

@ -115,41 +115,31 @@ describe("Ensures content topic is defined", () => {
});
};
expect(wrapper).to.throw(
"Routing Info must have the same content topic as the encoder"
);
expect(wrapper).to.throw("Content topic must be specified");
});
it("Encoder throws on empty string content topic", () => {
const wrapper = function (): void {
createEncoder({
contentTopic: "",
routingInfo: createRoutingInfo(testNetworkConfig, { contentTopic: "" })
routingInfo: testRoutingInfo
});
};
expect(wrapper).to.throw("AutoSharding requires contentTopic");
expect(wrapper).to.throw("Content topic must be specified");
});
it("Decoder throws on undefined content topic", () => {
const wrapper = function (): void {
createDecoder(
undefined as unknown as string,
createRoutingInfo(testNetworkConfig, {
contentTopic: undefined as unknown as string
})
);
createDecoder(undefined as unknown as string, testRoutingInfo);
};
expect(wrapper).to.throw("AutoSharding requires contentTopic");
expect(wrapper).to.throw("Content topic must be specified");
});
it("Decoder throws on empty string content topic", () => {
const wrapper = function (): void {
createDecoder(
"",
createRoutingInfo(testNetworkConfig, { contentTopic: "" })
);
createDecoder("", testRoutingInfo);
};
expect(wrapper).to.throw("AutoSharding requires contentTopic");
expect(wrapper).to.throw("Content topic must be specified");
});
});