UNPKG

@sinch/mcp

Version:

Sinch MCP server

23 lines 1.22 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const mailgun_tools_helper_1 = require("../../../../src/tools/email/utils/mailgun-tools-helper"); describe('hashing function', () => { it('should return a valid hash for a given input', () => { const input = 'test input'; const expectedHash = '9dfe6f15d1ab73af898739394fd22fd72a03db01834582f24bb2e1c66c7aaeae'; expect((0, mailgun_tools_helper_1.sha256)(input)).toBe(expectedHash); }); it('should return different hashes for different inputs', () => { const input1 = 'input one'; const input2 = 'input two'; expect((0, mailgun_tools_helper_1.sha256)(input1)).not.toBe((0, mailgun_tools_helper_1.sha256)(input2)); }); it('should return the same hash for the same input', () => { const input = 'consistent input'; expect((0, mailgun_tools_helper_1.sha256)(input)).toBe((0, mailgun_tools_helper_1.sha256)(input)); }); it('should handle empty strings', () => { expect((0, mailgun_tools_helper_1.sha256)('')).toBe('e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'); }); }); //# sourceMappingURL=mailgun-tools-helper.test.js.map