|
5333e281
|
2021-10-19T19:34:41
|
|
Added regex coverage (#3138)
|
|
2e834c8c
|
2021-10-19T14:59:04
|
|
Tests: Added `.html.test` files for replace `.js` language tests (#3148)
|
|
ae8888a0
|
2021-10-19T14:55:03
|
|
Tests: Added `TestCaseFile` class and generalized `runTestCase` (#3147)
|
|
3c61c8f7
|
2021-10-14T14:01:11
|
|
ESLint: Added `regexp/no-useless-flag` rule (#3150)
|
|
a394a14d
|
2021-10-05T22:13:13
|
|
Added more plugin tests (#1969)
|
|
99f3ddcd
|
2021-06-13T22:00:43
|
|
Tests: Automatically normalize line ends (#2934)
|
|
01cc18ed
|
2021-05-25T12:49:30
|
|
ESLint: Added eol-last rule (#2902)
|
|
212dc1c6
|
2021-05-25T12:46:45
|
|
ESLint: Added curly rule (#2901)
|
|
8dbf1217
|
2021-05-07T21:21:59
|
|
Tests: Fixed polynomial backtracking test (#2891)
|
|
a9a199b6
|
2021-05-03T22:56:44
|
|
Tests: Fixed languages test discovery
|
|
4492c5ce
|
2021-05-03T15:25:52
|
|
Tests: Test discovery should ignore unsupported file extensions (#2886)
|
|
cf7b0fd5
|
2021-05-01T14:40:00
|
|
ESLint: Added JSDoc plugin (#2869)
|
|
f46938e9
|
2021-04-17T22:35:25
|
|
ESLint: Added no-var rule (#2837)
|
|
b03e7eb0
|
2021-04-17T22:30:39
|
|
ESLint: Added semi rule (#2836)
|
|
9cae4461
|
2021-04-17T22:26:40
|
|
ESLint: Added quotes rule (#2835)
|
|
5bc405e7
|
2021-04-03T11:30:37
|
|
Tests: Fixed pretty print incorrectly calculating print width (#2821)
|
|
4c8b855d
|
2021-04-03T11:06:21
|
|
Tests: Added `--insert` and `--update` parameters to language test (#2809)
|
|
772d42be
|
2021-03-26T13:16:16
|
|
Added ESLint with minimal config (#2831)
|
|
8828500e
|
2020-12-22T10:54:55
|
|
Tests: Added strict checks for `Prism.languages.extend` (#2572)
|
|
8bfcc819
|
2020-11-21T01:17:39
|
|
Tests: Better pretty print (#2600)
This is a major improvement for the pretty-printer.
The main change is that `TokenStreamTransformer.prettyprint` now takes a Prism token stream instead of a simplified token stream. This means that it has a lot more information to work with and it uses that information.
It mostly behaves like the old pretty-printer with 3 main differences:
1. Tokens that contain a nested token stream that only contains a single string are printed as one line.
Example: `["namespace", ["java"]]`
2. The pretty-printer can now glue tokens together so that they are printed in a single line.
Example: `["number", "100"], ["operator", ".."], ["number", "100"]`
3. Line breaks in the input code may now cause empty lines in the output. Previously, only blank strings containing more at least 2 line breaks produce empty lines. This helps readability as it groups tokens together.
|
|
bafab634
|
2020-08-17T16:22:21
|
|
Tests: Added an option to accept the actual token stream (#2515)
|
|
681adeef
|
2020-06-28T03:16:17
|
|
Add extra newlines in pretty token streams (#2070)
The formatter for the simplified token streams of our test cases will now emit extra (empty) newlines if the tested code also has an empty line at those positions.
|
|
583e7eb5
|
2020-06-28T01:39:28
|
|
Tests: Always pretty-print token streams (#2421)
|
|
4ff555be
|
2020-06-28T01:34:29
|
|
Added JSDoc (#1782)
|
|
e756be3f
|
2020-06-27T21:43:24
|
|
Tests are now faster (#2165)
|
|
e416341f
|
2020-05-22T17:37:53
|
|
Test: Always use `components.json` (#2370)
All test files now consistently import `components.json` instead of `components.js`. The JS file is generated and can be outdated. This can be annoying when you're adding a language.
|
|
b4ed5ded
|
2020-05-19T01:47:03
|
|
Tests: Included console in VM context (#2353)
|
|
7a4a0c7c
|
2019-12-16T12:49:21
|
|
Standardized dependency logic implementation (#1998)
This adds a standard logic for handling dependencies between Prism components.
Right now, the download page, the `loadLanguages` function, and the test suite use the new dependency system.
|
|
c187e229
|
2019-10-16T12:06:22
|
|
Added test for unused capturing groups (#1996)
This adds a test that checks for unused capturing groups in patterns and another test which ensures that lookbehind groups are always the first thing being matched in a pattern.
|
|
007c9af4
|
2019-09-18T18:32:47
|
|
Tests: Simplified error message format (#2056)
The error messages will now only contain the actual token stream the failed test and a full path of the test file plus the line and column number of the position of the first difference between the expected token stream and the actual token stream.
|
|
e864d518
|
2019-08-29T23:24:17
|
|
Core: Fixed greedy targeting bug (#1932)
The `target` parameter defines the token which causes rematching. Rematching is done by recursively calling `matchGrammar` where `target` will be the current token name. The rematching is done if either a match was found or we reached the target token, whatever comes first.
The bug is that a token is identified by its name. But the name alone doesn't uniquely identify a token in a grammar because many tokens can have the same name (array).
This fixes this bug.
|
|
c3e74ea3
|
2019-03-24T22:50:22
|
|
Tests: Additional checks for Prism functions (#1803)
This adds additional checks for `extend` and `insertBefore` under `Prism.languages`.
|
|
832a9643
|
2019-03-10T21:30:58
|
|
Refactored tests (#1795)
This refactors all test related JS files.
|
|
9ea6d600
|
2019-03-10T18:55:23
|
|
Tests: Pretty-printed token stream (#1801)
This adds support for pretty-printed token streams in the output of error messages.
|
|
46e6f0c0
|
2018-04-05T08:51:43
|
|
Test suite: Fix indentation in test-case.js
|
|
5f9c078a
|
2018-03-25T13:46:42
|
|
Make ERB, Handlebars, PHP and Smarty highlight properly in NodeJS (#1367)
|
|
0e1a8b75
|
2018-03-20T08:54:48
|
|
Tests: Use the new components.js file directly
|
|
2b8321d3
|
2018-03-20T08:37:58
|
|
JSX: Add support for plain text inside tags (#1357)
* JSX: Add support for plain text inside tags
* JSX: Use a "plain-text" token to identify plain text
* TSX: Add support for plain text
* Fix test after merge
|
|
0a00d7f7
|
2017-02-10T17:10:19
|
|
Fix the PHP language
This patch is an attempt to fix the PHP language, when it is combined
with markup.
The problem is, that markup has a higher priority than all other tokens.
This leads to weird errors, where HTML tags are highlighted inside of
comments #197. One solution to this was to set the `greedy` flag for the
comment token, but this leads to far worse errors like #1097.
This patch should fix both issues #197 and #1097, by switching the
grammar to markup on the fly. One potential problem is, that it relies
on the `<?php` tag to detect if markup is present. So if a PHP file
contains only markup and no PHP code at all, the result will look
broken.
|
|
dfc19413
|
2016-11-09T01:57:46
|
|
Add support for the Jolie language (#1014)
* Added component for the Jolie language
* Added Jolie among the supported components
* update for merge
- revised jolie component
- added tests
- added code example
- minified with `gulp`
* fixes
* fixes
* fixed Jolie html file example and highlight for punctuation
* fixed indentation in test html file and added comma as punctuation
|
|
c1a0c1bd
|
2016-07-11T20:37:47
|
|
Added TestCase.runTestsWithHooks + add missing tests. Updated documentation for test suite.
|
|
5ade8a58
|
2015-10-06T08:25:54
|
|
Test runner: Allow to run tests for only some languages
|
|
a896f0a6
|
2015-08-30T16:06:37
|
|
Drastically increased the number of dashes (from 4 to 10) required for separations in test files, to prevent conflicts with languages syntax.
|
|
791dad0d
|
2015-08-27T20:57:37
|
|
Tests: Increase the minimum number of dashes for the separation + fix test-suite page to match the actual behaviour.
|
|
ac792bd7
|
2015-08-25T08:04:33
|
|
Prism loader must handle dependency array.
|
|
d1b2e206
|
2015-08-19T00:19:45
|
|
Fix test runner: it must use the last language by default
|
|
2bc55185
|
2015-07-26T14:34:41
|
|
Improve support of node 10.x
|
|
a13c87b9
|
2015-07-26T14:27:38
|
|
Added support for specifying the main language to load in test cases
You can add an exclamation mark anywhere in the name to load it as main language. If you do not specify anything, the first entry is used as main language
css+markup! --> markup is main language
css+markup --> css is main language
|
|
1e0b8d9d
|
2015-07-26T14:08:47
|
|
Fixed code style issues
|
|
f05e0797
|
2015-07-15T20:01:39
|
|
Updated simplification of token stream
It now strips empty values
|
|
3a3cd268
|
2015-07-15T19:35:07
|
|
Extract simplification of token stream
Pull the token stream transformation out of the test case into its own component.
|
|
5c2f9e0a
|
2015-07-15T19:29:27
|
|
Use consistent quote style
|
|
9ce5838a
|
2015-07-14T10:51:35
|
|
Catch JSON parse error to provide a unified error reporting in the test runner
|
|
9619d4cb
|
2015-07-14T10:46:57
|
|
Implement support for simplifying nested token streams
|
|
aec5fcc4
|
2015-06-13T16:41:31
|
|
Added return type definition
|
|
09898e8e
|
2015-06-13T16:37:07
|
|
Support language inclusion tests
By using composed language names "language+language2+language3" you can test language inclusion or do integration tests.
|
|
829f8a86
|
2015-06-13T15:24:53
|
|
New file extension for test case files: .test
## All test case files are now required to have the ".test" extension.
This prevents issues with syntax highlighting in common IDEs and also prevents the test system to choke on non-testcase files in these directories (like `.DS_Store` or `Thumbs.db`).
## Hide the ".test" extension in the description of the test cases
The message for a testcase `blabla.test` will now just read:
> 1) Testing language 'css' – should pass test case 'blabla':
|
|
be5e037b
|
2015-06-13T15:12:21
|
|
Added support for test case comments
|
|
d1f90520
|
2015-06-01T20:39:11
|
|
Implemented test runner
|