Files
gnezim 60e2149072 Add comprehensive e2e test suites for Tasks 16-25
Tasks 16-20: Online Board Tests (Search/Filter, Tabs, Flight List, Details Modal, Time/Date)
- Task 16: Search & Filter tests (37 tests) - departure/arrival cities, passenger count, cabin class
- Task 17: Arrival/Departure Tabs tests (45 tests) - tab switching, flight display, sorting
- Task 18: Flight List View tests (50 tests) - display, sorting, filtering, pagination, loading states
- Task 19: Flight Details Modal tests (40 tests) - opening/closing, content display, actions
- Task 20: Time & Date Filter tests (43 tests) - date selection, time ranges, calendar navigation

Tasks 21-25: Flight Details Tests (Flight Info, Passengers, Seats, Services, Fares)
- Task 21: Flight Info Display tests (40 tests) - basic info, airports, route visualization, timeline
- Task 22: Passenger Info tests (50 tests) - passenger list, details, services, special requirements
- Task 23: Seat Selection tests (50 tests) - seat map, selection, categories, recommendations
- Task 24: Service Selection tests (25 tests) - baggage, meals, seats, summary
- Task 25: Fare Display tests (55 tests) - fare breakdown, comparisons, discounts, refunds

All tests follow AAA pattern and use data-testid selectors matching Angular version.
Total: 245 tests across 10 feature suites.
2026-04-05 19:25:03 +03:00

2 lines
4.9 KiB
JavaScript
Raw Permalink Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("primereact/api"),n=require("primereact/componentbase"),o=require("primereact/hooks"),r=require("primereact/ripple"),l=require("primereact/tooltip"),a=require("primereact/utils");function i(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var c=i(e);function u(){return u=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)({}).hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},u.apply(null,arguments)}function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function p(e,t){if("object"!=s(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t||"default");if("object"!=s(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function f(e){var t=p(e,"string");return"symbol"==s(t)?t:t+""}function b(e,t,n){return(t=f(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var d=n.ComponentBase.extend({defaultProps:{__TYPE:"ToggleButton",id:null,onIcon:null,offIcon:null,onLabel:"Yes",offLabel:"No",iconPos:"left",invalid:!1,style:null,className:null,checked:!1,tabIndex:0,tooltip:null,tooltipOptions:null,onChange:null,onFocus:null,onBlur:null,children:void 0},css:{classes:{root:function(e){var t=e.props;return a.classNames("p-togglebutton p-component",{"p-disabled":t.disabled,"p-highlight":t.checked,"p-invalid":t.invalid})},input:"p-togglebutton-input",box:function(e){return a.classNames("p-button p-component",{"p-button-icon-only":e.hasIcon&&!e.hasLabel})},icon:function(e){var t=e.props,n=e.label;return a.classNames("p-button-icon",{"p-button-icon-left":"left"===t.iconPos&&n,"p-button-icon-right":"right"===t.iconPos&&n})},label:"p-button-label"}}});function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(Object(n),!0).forEach((function(t){b(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var y=c.memo(c.forwardRef((function(e,i){var s=o.useMergeProps(),p=c.useContext(t.PrimeReactContext),f=d.getProps(e,p),b=c.useRef(null),m=d.setMetaData({props:f}),y=m.ptm,v=m.cx;n.useHandleStyle(d.css.styles,m.isUnstyled,{name:"togglebutton"});var h=f.onLabel&&f.onLabel.length>0&&f.offLabel&&f.offLabel.length>0,O=f.onIcon&&f.offIcon,P=h?f.checked?f.onLabel:f.offLabel:" ",j=f.checked?f.onIcon:f.offIcon,E=function(e){f.disabled||!f.onChange||f.readonly||f.onChange({originalEvent:e,value:!f.checked,stopPropagation:function(){e.stopPropagation()},preventDefault:function(){e.preventDefault()},target:{name:f.name,id:f.id,value:!f.checked}})};c.useImperativeHandle(i,(function(){return{props:f,focus:function(){return a.DomHandler.focusFirstElement(b.current)},getElement:function(){return b.current}}})),o.useMountEffect((function(){f.autoFocus&&a.DomHandler.focusFirstElement(b.current)}));var N=a.ObjectUtils.isNotEmpty(f.tooltip),I=f.disabled?-1:f.tabIndex,k=function(){if(O){var e=s({className:v("icon",{label:P})},y("icon"));return a.IconUtils.getJSXIcon(j,g({},e),{props:f})}return null}(),w=s({className:v("label")},y("label")),x=s({ref:b,id:f.id,className:a.classNames(f.className,v("root",{hasIcon:O,hasLabel:h})),"data-p-highlight":f.checked,"data-p-disabled":f.disabled},d.getOtherProps(f),y("root")),D=s({id:f.inputId,className:v("input"),style:f.style,onChange:E,onFocus:function(e){var t;null==f||null===(t=f.onFocus)||void 0===t||t.call(f,e)},onBlur:function(e){var t;null==f||null===(t=f.onBlur)||void 0===t||t.call(f,e)},onKeyDown:function(e){32===e.keyCode&&(E(e),e.preventDefault())},tabIndex:I,type:"checkbox","aria-invalid":f.invalid,disabled:f.disabled,readOnly:f.readonly,value:f.checked,checked:f.checked,"aria-label":f["aria-label"],"aria-labelledby":f["aria-labelledby"]},y("input")),L=s({className:a.classNames(f.className,v("box",{hasIcon:O,hasLabel:h}))},y("box"));return c.createElement(c.Fragment,null,c.createElement("div",x,c.createElement("input",D),c.createElement("div",L,k,c.createElement("span",w,P),c.createElement(r.Ripple,null))),N&&c.createElement(l.Tooltip,u({target:b,content:f.tooltip,pt:y("tooltip")},f.tooltipOptions)))})));y.displayName="ToggleButton",exports.ToggleButton=y;