devextreme
Version:
HTML5 JavaScript Component Suite for Responsive Web Development
47 lines (46 loc) • 1.82 kB
JavaScript
/**
* DevExtreme (cjs/__internal/grids/new/card_view/content_view/content/card/caption.test.js)
* Version: 25.1.3
* Build date: Wed Jun 25 2025
*
* Copyright (c) 2012 - 2025 Developer Express Inc. ALL RIGHTS RESERVED
* Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/
*/
;
var _inferno = require("inferno");
var _globals = require("@jest/globals");
var _caption = require("./caption");
(0, _globals.describe)("Content View", (() => {
(0, _globals.describe)("Caption", (() => {
(0, _globals.it)("should render title", (() => {
const container = document.createElement("div");
(0, _inferno.render)((0, _inferno.createComponentVNode)(2, _caption.Caption, {
field: {
column: {
caption: "TEST_TITLE"
}
}
}), container);
(0, _globals.expect)(container).toMatchSnapshot()
}));
(0, _globals.it)("should render template with title", (() => {
const container = document.createElement("div");
(0, _inferno.render)((0, _inferno.createComponentVNode)(2, _caption.Caption, {
field: {
column: {
caption: "TEST_TITLE"
}
},
template: _ref => {
let {
field: field
} = _ref;
return (0, _inferno.createVNode)(1, "div", null, field.column.caption, 0, {
"test-template": "true"
})
}
}), container);
(0, _globals.expect)(container).toMatchSnapshot()
}))
}))
}));