"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const react_1 = __importDefault(require("react"));
const experimental_ct_react_1 = require("@playwright/experimental-ct-react");
const Question_story_1 = require("../stories/exam/Question.story");
experimental_ct_react_1.test.describe('TextAnswerInput', () => {
    (0, experimental_ct_react_1.test)('integer input accepts unicode minus sign', async ({ mount }) => {
        const component = await mount(react_1.default.createElement(Question_story_1.QuestionStory, { examXml: examXml }));
        await component.locator('input').type('−5');
        await (0, experimental_ct_react_1.expect)(component.locator('input')).toHaveValue('\u22125');
    });
    (0, experimental_ct_react_1.test)('integer input accepts ascii hyphen minus sign', async ({ mount }) => {
        const component = await mount(react_1.default.createElement(Question_story_1.QuestionStory, { examXml: examXml }));
        await component.locator('input').type('-5');
        await (0, experimental_ct_react_1.expect)(component.locator('input')).toHaveValue('\u002D5');
    });
});
const examXml = `<e:exam xmlns:e="http://ylioppilastutkinto.fi/exam.xsd" xmlns="http://www.w3.org/1999/xhtml" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://ylioppilastutkinto.fi/exam.xsd https://abitti.net/schema/exam.xsd" exam-schema-version="0.5">
    <e:exam-versions>
        <e:exam-version lang="fi-FI"/>
    </e:exam-versions>
    <e:exam-title>Exam</e:exam-title>
    <e:exam-instruction/>
    <e:table-of-contents/>
    <e:section>
        <e:section-title>Section</e:section-title>
        <e:section-instruction/>
        <e:question display-number="1">
            <e:question-title>Kokonaislukutehtävä</e:question-title>
            <e:question-instruction>
                <br/>
            </e:question-instruction>
            <e:text-answer type="integer" max-score="1"/>
        </e:question>
    </e:section>
</e:exam>`;
//# sourceMappingURL=TextAnswerInput.test.js.map