Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
it('compiles the binding to a TranslationBindBindingInstruction', function () {
const [sut] = setup();
const syntax: AttrSyntax = { command: 't.bind', rawName: 't.bind', rawValue: 'obj.key', target: 'bind' };
const actual = sut.compile({
command: new AttrBindingCommand(),
flags: (void 0)!,
expression: { syntax } as unknown as AnyBindingExpression,
syntax
});
assert.instanceOf(actual, TranslationBindBindingInstruction);
});
});
it('compiles the binding to a TranslationParametersBindingInstruction', function () {
const sut = setup();
const syntax: AttrSyntax = { command: 't-params.bind', rawName: 't-params.bind', rawValue: '{foo: "bar"}', target: '' };
const plainAttributesymbol: PlainAttributeSymbol = {
command: new AttrBindingCommand(),
flags: (void 0)!,
expression: { syntax } as unknown as AnyBindingExpression,
syntax
};
const actual = sut.compile(plainAttributesymbol);
assert.instanceOf(actual, TranslationParametersBindingInstruction);
});
});