"use strict";

const {
  convertCode
} = require('../utilities');

test('The &&= Operator', () => {
  const inputCode = `let x = 10;
x &&= 5;`;
  const outputCode = `let x = 10;
x &&= 5;`;
  expect(convertCode(inputCode)).toBe(outputCode);
});
test('The ||= Operator', () => {
  const inputCode = `let x = 10;
x ||= 5;`;
  const outputCode = `let x = 10;
x ||= 5;`;
  expect(convertCode(inputCode)).toBe(outputCode);
});
test('The ??= Operator', () => {
  const inputCode = `let x = 10;
x ??= 5;`;
  const outputCode = `let x = 10;
x ??= 5;`;
  expect(convertCode(inputCode)).toBe(outputCode);
});