UNPKG

yhtml5-test

Version:

A test framework for front-end projects

18 lines (14 loc) 575 B
/** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import { getLinesAround } from '../utils/getLinesAround'; var arr = ['one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight']; test('should return lines around from a string', function () { expect(getLinesAround(4, 2, arr)).toMatchSnapshot(); }); test('should return lines around from an array', function () { expect(getLinesAround(4, 2, arr.join('\n'))).toMatchSnapshot(); });