mirror of
https://github.com/withastro/astro.git
synced 2024-12-23 21:53:55 -05:00
4349254376
* Migrate Telemetry tests to node:test * Remove fallback to chai * Remove chai and mocha dependencies * Fix trailing comma * Fix pnpm-lock.yaml desync * Add back old tests with progression * Convert tests to node:test * Remove unused dependencies * Remove artifact changes * Revert more artifacts * Fix more
16 lines
604 B
JavaScript
16 lines
604 B
JavaScript
import assert from 'node:assert/strict';
|
|
import { describe, it } from 'node:test';
|
|
import convert from '../vnode-children.js';
|
|
|
|
describe('experimental react children', () => {
|
|
it('has undefined as children for direct children', () => {
|
|
const [imgVNode] = convert('<img src="abc"></img>');
|
|
assert.deepStrictEqual(imgVNode.props.children, undefined);
|
|
});
|
|
|
|
it('has undefined as children for nested children', () => {
|
|
const [divVNode] = convert('<div><img src="xyz"></img></div>');
|
|
const [imgVNode] = divVNode.props.children;
|
|
assert.deepStrictEqual(imgVNode.props.children, undefined);
|
|
});
|
|
});
|