* chore: merge canavs into x-pack
squashed, since 6.x history isn't important and i want to be able to rebase...
* chore: eslint fixes in canvas
adds license headers and includes project linting overrides
* Chore: Reorg the x-pack gulp tasks (#22785)
- Removes deprecated, non-functional lint scripts
- Removes some unused (and barely used) dependencies
- Replaces deprecated `gulp-util` dependency
- Adds eslint rule to prevent future use of deprecated `gulp-util` dependency
- Moves all gulp tasks into `tasks` path
- Moves `gulp_helpers` into `tasks/helpers`
- All tasks in `gulpfile.js` were moved into `tasks` and broken up by domain
This is basically a no-op moving files around PR. All the existing tasks appear to work the same with these changes.
<img width="334" alt="screenshot 2018-09-06 15 42 45" src="https://user-images.githubusercontent.com/404731/45188971-8618c000-b1eb-11e8-9b26-b072ccc7ddb7.png">
* chore: rename files to match rules
* chore: copy canvas dependencies
* chore: reduce package.json to essentials
* chore: make canvas work in xpack
* chore: make browser tests work
* chore: fix include paths
node_modules is in a different relative path
* chore: fix ml tests with canvas code in x-pack
explicitely enable state management so the mlStateFactory tests pass
* chore: fix RBAC tests with canvas
* chore: split up the xpack prepare scripts
* chore: canvas tasks - dev, peg, and plugins
get dev, peg, and plugin building tasks working
* chore: canvas tasks - local tests
* chore: additional file cleanup
* chore: yarn lockfiles and eslint fixes
license headers and some small formatting stuff
I'd really like to upgrade to Typescript 3 for its `unknown` type, but we need to upgrade to `jest@23` to support a recent version of `ts-jest@23`.
The [jest changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md) breaks down the breaking changes in 23.x, but I found it to be slightly incomplete so I've broken down the changes that actually caused breaks for us here, and addressed each in individual commits to make review a little easier:
- the `testURL` config default was changed from `about:blank` to `http://localhost`
- this cause some XHR requests powered by JSdom to start failing. It seems these requests just do nothing in master but start to fail when JSdom is initialized with an actual URL... I think we would ideally stop sending meaningless XHR requests in the tests, but it was a lot easier to just set the config to `about:blank` for now, and we can worry about cleanup later if necessary
- `expect(...).toThrow()` only passes if an actual error was thrown.
- In two places in the index pattern code we were throwing strings, which broke the assertions. Fortunately/Unfortunately the errors are not being consumed by anything, so I was able to wrap them in `new Error()` without causing any issues.
- snapshots of mock functions now include a `results` array, detailing the return values of the function
- React fragments are now serialized as `<React.Fragment>` instead of `<UNDEFINED>`
- undefined props in React components are now stripped from snapshots
- minor changes to the ordering of mocks, imports resolution, and before hooks caused the uiSettings API tests to start breaking, but I'm replacing them with totally new tests in #22694 so I just deleted them here
- mocks created with `jest.spyOn()` that are restored now have their `mock.calls` reset, so some of the kbn-pm tests stated failing. This was fixed by restoring them with `jest.restoreAllMocks()` rather than trying to do it before the assertions
This is an attempt to write a log capture integration for the functional test runner that will collect all log output written during a test, prevent it from being written to stdout to lower the amount of work Jenkins master has to do and include the entire log output for each test in the junit report. I'm slightly concerned about the amount of memory we'll be using to store a copy of the logs for each test, but streaming the XML report isn’t easy and there doesn’t seem to be a library out there to help. If we decide it’s torally necessary we might be able to figure it out.
This adds support for autoprefixer which we have been using in Webpack.
Additionally, we have improved the watching functionality and now update builds based directly on their dependencies an not an assumption that the files are children.
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* set kibana locale in kibana.yml config
* remove accept-language-parser
* remove unnecessary tests
* fix readme description, fix description for locale in kibana.yml
* add point, that i18n.locale option should have exact match
* update kbn/i18n README
* Update README.md
* use getUiTranslations in render_mixin, remove i18n_mixin
* move registering translation files to mixin function
* Switching from jade to pug (#21047)
* Upgrading pug
* Switching .jade to .pug and fixing templates
* Renaming the I18N usages of jade to pug
* No more jade in I18N
* Renaming root_redirect to .pug
In order to make the awesome new kfetch api easier to consume in purely TypeScript projects, and since it's a pretty small module with very few dependencies, I converted it to TypeScript.
Along with kfetch I also started a type definition file for `ui/chrome` that we can extend as we go, but will likely be unnecessary after #19992
* bump eui
* Fixed breaking `EuiPage` changes
Mainly adding `EuiPageBody`’s where there were none
* bump to 3.0, remove duplicate declaration of EuiFlyoutBody, update jest snapshots
* bump eui
* bump to 3.0, remove duplicate declaration of EuiFlyoutBody, update jest snapshots
* Update jest snapshots in xpack
This upgrades TypeScript to version 2.9.2. My main motivation is the support for generic type arguments in JSX elements and tagged templates (e.g. for `styled-components`).
Problems arising from breaking changes in the new TypeScript version have been mitigated by:
* setting the `keyofStringsOnly` option until impacted code has been
future-proofed
* Restricting some joi-related generics
See the [release notes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-9.html) for details.
Some follow-up tasks should be:
* Update EUI to support the new `keyof` behaviour
* Update new platform TypeScript code to support new `keyof` behaviour
* Remove `keyofStringsOnly` setting