Rick Winfrey
8c3d9d0d76
Add JSON output format JavaScript JSONTestCases
2016-10-27 20:46:12 -05:00
Rick Winfrey
16c6e1da59
++diff-summary javascript test cases
2016-10-27 20:44:36 -05:00
Rick Winfrey
3cfbcd102d
Update SemanticGitDiffSpec to handle ExpectedResult data type
2016-10-27 20:43:30 -05:00
Rick Winfrey
4936f282ad
Simplify the structure of generator files; update GenerateTestCases
2016-10-27 20:42:46 -05:00
Rick Winfrey
df231ca64c
Add ToJSON and FromJSON instances for JSONTestCase and ExpectedResult
2016-10-27 20:40:20 -05:00
Rick Winfrey
4ac2608749
Add HashMap
2016-10-27 20:23:31 -05:00
Timothy Clem
ba305a2a44
Parse module declarations
2016-10-27 12:47:27 -07:00
Timothy Clem
c21307b5f7
Parse for iterator syntax
2016-10-27 10:07:24 -07:00
Timothy Clem
539a68f06e
Parse lambdas
2016-10-27 09:24:28 -07:00
Timothy Clem
f09c834e01
Parse array and percent array syntax
2016-10-27 08:30:34 -07:00
Timothy Clem
fec86e0a88
New tree-sitter and fix string delimiters
2016-10-27 08:24:43 -07:00
Timothy Clem
2a9e26f144
Support regex literals
2016-10-26 15:44:53 -07:00
Timothy Clem
644d101394
Support or, and operators
2016-10-26 15:22:59 -07:00
Rick Winfrey
682a1323fe
Add ExpectedResult type
...
- This enables the use of Effects so that we can run multiple effects
that generate different IO values, but are typed singularly as an
ExpectedResult type
2016-10-26 17:02:04 -05:00
Rick Winfrey
a31a883b30
Auto formatting
2016-10-26 17:01:15 -05:00
Timothy Clem
5dd53c0b93
if/unless modifiers and (sort of) unless statements
2016-10-26 14:49:51 -07:00
Timothy Clem
3bbfb765a5
Parse if, with some caveats
2016-10-26 14:32:08 -07:00
Timothy Clem
013f6392ff
Parse while and until statements and modifiers
2016-10-26 12:54:21 -07:00
Timothy Clem
986a3572d4
Merge remote-tracking branch 'origin/master' into ruby
2016-10-26 10:30:29 -07:00
Timothy Clem
1b6c70f4ee
Parse yield and return
2016-10-26 10:27:38 -07:00
Timothy Clem
eb52ca6f90
Handle method arguments, updated tree-sitter-ruby
2016-10-26 10:14:39 -07:00
Timothy Clem
1bc5ba394a
Classes, member invocation, case statements
2016-10-25 11:36:30 -07:00
Timothy Clem
649119c967
Method invocation
2016-10-24 12:23:10 -07:00
Timothy Clem
56c2dae42f
Bring in LOTS more of the ruby grammar
2016-10-24 10:43:31 -07:00
Timothy Clem
994b7a613e
Ruby math assignment (todo: broken)
2016-10-21 15:52:40 -07:00
joshvera
8b8e18c323
Map source_file to Module Syntax
2016-10-21 18:34:22 -04:00
Timothy Clem
b8463b6039
Ruby delimiters (sort of)
2016-10-21 14:41:04 -07:00
Timothy Clem
22c617e9e9
Ruby interpolation parsing
2016-10-21 13:55:00 -07:00
Timothy Clem
f5621a7ed0
Test parsing ruby numbers, strings, and symbols
2016-10-21 12:59:35 -07:00
joshvera
94239b4602
Merge remote-tracking branch 'origin/master' into go-parser
2016-10-21 13:53:33 -04:00
Rick Winfrey
5be0a11707
Update Import tests
2016-10-20 17:27:30 -05:00
Timothy Clem
caeeb79799
Regenerate ruby test corpus to get valid shas
2016-10-20 10:36:33 -07:00
Timothy Clem
00cb51b083
Fix multiline comment followed by comment bug
2016-10-20 10:07:15 -07:00
Rick Winfrey
1a787335b8
Update tests
2016-10-19 18:10:28 -05:00
Timothy Clem
e4bb574700
Catch integer literals and abbreviate in summaries
2016-10-19 11:02:02 -07:00
Timothy Clem
fc25ff9e86
Add ruby corpus as submodule
2016-10-19 10:36:56 -07:00
Timothy Clem
456bbb41ae
Handle basic assignment for ruby
2016-10-19 10:34:49 -07:00
Timothy Clem
c213e85e9c
Allow running integration tests only for one language
...
The --test-arguments can be passed like this:
stack build :integration-test --test-arguments "--language=ruby"
--language is naively parsed right now just to avoid getting in the way
of hspec's option parsing.
2016-10-19 10:15:58 -07:00
Rick Winfrey
1f5c73143d
++import.json tests
2016-10-18 16:54:15 -05:00
joshvera
d5532c9299
fix insert assignment test
2016-10-18 16:56:33 -04:00
joshvera
7809618716
Add template syntax support
2016-10-18 16:10:22 -04:00
joshvera
13c615731e
Replace output with failing tests
2016-10-18 14:54:54 -04:00
joshvera
1bff390a85
Change var to assignment
2016-10-18 14:52:48 -04:00
joshvera
f262eb8b4e
Add go.json generator and var.json
2016-10-18 14:49:45 -04:00
joshvera
ec00e4b0c3
Add go test submodule
2016-10-18 14:49:29 -04:00
Rick Winfrey
3b984eb470
++javascript
2016-10-18 10:34:49 -05:00
Rick Winfrey
99e070e107
Remove if-else generated file
2016-10-17 18:51:23 -05:00
Rick Winfrey
43e082c85f
Remove import generated file
2016-10-17 18:50:47 -05:00
Rick Winfrey
242654b05f
Update tests
2016-10-17 18:41:03 -05:00
Rick Winfrey
dfc11385d8
++tests
2016-10-14 13:40:07 -05:00
joshvera
1ec96efd63
bump tests
2016-10-14 12:19:31 -04:00
joshvera
3839a8605a
Bump tests
2016-10-14 12:12:38 -04:00
Rick Winfrey
0262cb0879
Merge branch 'master' into improve-anonymous-funs
2016-10-13 17:56:39 -05:00
joshvera
ca129b2449
bump tests
2016-10-13 18:02:14 -04:00
Rick Winfrey
383573aa3d
Merge branch 'master' into if-else-if
2016-10-13 17:01:23 -05:00
joshvera
4f978b7586
No quotes around anonymous functions
2016-10-13 17:58:17 -04:00
Rick Winfrey
80ebddae5c
Bump tests
2016-10-13 16:44:36 -05:00
joshvera
98627b74b7
Merge remote-tracking branch 'origin/master' into improve-anonymous-funs
2016-10-13 17:39:42 -04:00
Josh Vera
9f9dc4feab
Merge branch 'master' into improve-memory-usage
2016-10-13 16:21:11 -04:00
joshvera
b5ff4178e9
scope to getLabel
2016-10-13 16:16:50 -04:00
joshvera
be1ca766c1
Quote anonymous and brace exports
2016-10-13 12:56:27 -04:00
joshvera
73b947f71b
Update tests
2016-10-13 12:08:44 -04:00
joshvera
10b6852882
update tests
2016-10-12 19:44:27 -04:00
joshvera
c608d62a3a
Import from Diffing
2016-10-12 19:33:05 -04:00
joshvera
dfe8648a11
Fix tests
2016-10-12 19:19:36 -04:00
Timothy Clem
1859df9500
Test to no longer expect summaries for comments
2016-10-12 14:21:40 -07:00
Rick Winfrey
1234f5dbc3
++javascript tests
2016-10-12 14:59:58 -05:00
Rick Winfrey
d222090c37
Update if-else.json tests
2016-10-12 14:55:59 -05:00
joshvera
6ba48666ed
bump files
2016-10-11 16:18:26 -04:00
joshvera
440d168273
bump tests
2016-10-11 15:13:51 -04:00
joshvera
deb5a0f018
Fix SourceSpan in tests
2016-10-11 15:12:48 -04:00
joshvera
007a1580fe
Merge remote-tracking branch 'origin/master' into add-source-spans
2016-10-11 13:03:43 -04:00
joshvera
e57c80940e
bump tests
2016-10-11 12:52:26 -04:00
Rick Winfrey
329ce63a8e
++tests
2016-10-11 11:07:57 -05:00
joshvera
11d5cdcde7
Bump tests
2016-10-11 12:00:34 -04:00
joshvera
4fb07c28b6
Bump tests
2016-10-11 11:54:47 -04:00
joshvera
fbb6ddbff4
Bump tests
2016-10-11 11:26:57 -04:00
joshvera
a08cad66d0
++javascript
2016-10-11 11:13:44 -04:00
joshvera
399d01af97
update tests
2016-10-11 11:12:20 -04:00
joshvera
624918b113
remove files
2016-10-11 11:10:16 -04:00
joshvera
d95283f4a1
Merge remote-tracking branch 'origin/master' into add-source-spans
2016-10-11 10:45:22 -04:00
Rick Winfrey
1569611257
Update JSONtestcases shas
2016-10-10 12:39:22 -05:00
Rick Winfrey
d6f9104237
Update tests
2016-10-07 16:43:01 -05:00
Rick Winfrey
9a3fccc1e1
Update tests
2016-10-07 15:58:51 -05:00
joshvera
f7e0cb53dd
++javascript
2016-10-07 11:29:44 -04:00
joshvera
c0a8483263
Merge remote-tracking branch 'origin/master' into add-source-spans
2016-10-07 11:28:57 -04:00
Rick Winfrey
4453cd1ad9
Move javascript diff summary JSON test case files
2016-10-07 10:26:45 -05:00
Rick Winfrey
bbe8b00b34
++javascript
2016-10-07 10:21:14 -05:00
Rick Winfrey
3e23076ecc
Merge branch 'master' into import-export-syntax
2016-10-07 10:20:11 -05:00
Timothy Clem
da90b74044
New parsing of function params
2016-10-06 15:20:05 -07:00
joshvera
15cd4777e6
Add SourceSpans to customize ToJSON output for These SourceSpan SourceSpan
2016-10-06 17:55:54 -04:00
joshvera
39e3a01533
Fix up DiffSummarySpec ranges
2016-10-06 15:12:14 -04:00
Timothy Clem
3d7c8cf67d
Fix anonymous function parsing and summarizing
2016-10-06 12:05:10 -07:00
Timothy Clem
976b299071
Fix quoted strings
2016-10-06 11:42:21 -07:00
joshvera
f1a1c759b0
Fix some test errors
2016-10-06 14:20:58 -04:00
Timothy Clem
68b1cfac64
And the repo path is slightly different
2016-10-06 09:04:03 -07:00
Timothy Clem
02853cc422
Path still not quite right
2016-10-06 09:02:38 -07:00
Timothy Clem
47731b3faa
Bring back the right path here
2016-10-06 08:56:27 -07:00
Timothy Clem
068481b35b
Merge remote-tracking branch 'origin/master' into project-reorg
2016-10-06 08:45:04 -07:00
Timothy Clem
f004a5c3db
New path for test corpus
2016-10-05 17:16:59 -07:00
Timothy Clem
6cbfa91475
Try out moving project around
2016-10-05 16:17:46 -07:00
joshvera
b7df878c4b
Update specs
2016-10-05 17:41:00 -04:00
joshvera
4f41619c8e
Merge remote-tracking branch 'origin/master' into rws-large-diffs
2016-10-05 12:17:29 -04:00
joshvera
07b7b7598e
Rename prependSummary to appendSummary and update tests
2016-10-05 11:56:42 -04:00
joshvera
1f52815f9c
Merge 'origin/master' into rws-large-diffs
2016-10-03 19:02:36 -04:00
Rick Winfrey
cf64cf41d9
Update DiffSummarySpec
2016-10-03 16:39:29 -05:00
Timothy Clem
45a12c54f0
Fix testDiff in DiffSummarySpecs too
2016-09-30 14:15:02 -07:00
joshvera
bfe57829d6
Merge remote-tracking branch 'origin/master' into rws-large-diffs
2016-09-27 10:34:19 -04:00
Timothy Clem
b5c45f8c7c
New expected json output for dictionary
2016-09-20 10:31:50 -07:00
Timothy Clem
bf2c5966ba
Merge branch 'master' of https://github.com/github/semantic-diff into improve-number-summaries
2016-09-20 08:01:37 -07:00
Timothy Clem
7c390d9081
Merge branch 'master' of https://github.com/github/semantic-diff into improve-number-summaries
2016-09-19 15:27:00 -07:00
Timothy Clem
d632011a3c
Fix up tests
2016-09-19 15:23:07 -07:00
Rob Rix
8cec95aad4
Merge branch 'master' into pretty-print-expectations
...
# Conflicts:
# script/cibuild-semantic-diff
# script/cibuild-semantic-diff-linux
# test/RangeSpec.hs
# test/Spec.hs
2016-09-20 05:56:12 +09:00
Timothy Clem
edb69e2c69
Fix test, category printed as NumberLiteral now
2016-09-19 13:33:02 -07:00
Rob Rix
38d6bbe644
Merge branch 'master' into ghc8
2016-09-17 20:45:58 -04:00
joshvera
925fdfaeaf
remove &&& import
2016-09-16 11:52:31 -04:00
joshvera
0535744ebc
more imports
2016-09-16 11:48:58 -04:00
Rob Rix
e6372deeb6
🔥 a redundant constraint.
2016-09-15 18:38:18 -04:00
Rob Rix
8d465b96ab
Annotate the leaf type.
2016-09-15 18:34:54 -04:00
Rob Rix
97b7f27683
Give a type signature for decorate
.
...
This fixes a problem where ghc will loop forever trying to infer the
type.
2016-09-15 18:32:57 -04:00
Rob Rix
d0395cd227
🔥 some redundant parens.
2016-09-15 18:12:32 -04:00
Rob Rix
64d1d6b407
Monoid/Semigroup stuff.
2016-09-15 17:21:37 -04:00
Rick Winfrey
1a25bf9a11
Add RangeSpec to specs
2016-09-14 16:45:34 -05:00
Rick Winfrey
a4c5a26533
Add pretty diff expectations to semantic diff tests
2016-09-14 16:45:23 -05:00
Rob Rix
86d2a3950f
Revert " 🔥 a redundant import."
...
This reverts commit dc5698979818d0057eb558ec3ce2d8e09c941f44.
2016-09-14 02:44:26 -04:00
Rob Rix
85bb9d577a
Revert "Move totalSpan into Source."
...
This reverts commit 3085a4efe5b6b3e8807df6a05db784afccab58e2.
2016-09-14 02:41:28 -04:00
Rob Rix
25306dba99
🔥 a redundant import.
2016-09-14 02:19:24 -04:00
Rob Rix
6317228466
Move totalSpan into Source.
2016-09-14 01:57:51 -04:00
Rob Rix
a6633a5351
🔥 a redundant binding.
2016-09-13 15:10:49 -04:00
Rob Rix
1c335df1f0
Verify that sourceSpanToRange computes correct ranges within lines.
2016-09-13 15:04:17 -04:00
Rob Rix
e6f4db8ee8
Compute the insetting of SourceSpans & Ranges.
2016-09-13 15:03:58 -04:00
Rob Rix
50e5f8a411
Verify that sourceSpanToRange computes multi-line ranges.
2016-09-13 14:27:52 -04:00
Rob Rix
8de562b88e
Verify that totalSpan covers multiple lines.
2016-09-13 14:27:36 -04:00
Rob Rix
1b890bcde4
Verify that totalSpan covers single lines.
2016-09-13 14:27:29 -04:00
Rob Rix
8bdf162874
Rename the line-by-line test.
2016-09-13 14:27:15 -04:00
Rob Rix
c157962785
Add a helper to compute the total span of some source.
2016-09-13 14:27:05 -04:00
Rob Rix
6ce0ce5e26
Indentation.
2016-09-13 13:14:02 -04:00
Rob Rix
c5fed4ac25
Test sourceSpanToRange across arbitrary sources.
2016-09-13 12:37:59 -04:00
Rob Rix
61dd23789d
Rename the test.
2016-09-13 12:32:28 -04:00
Rob Rix
5459bd4313
🔥 This was wrong.
2016-09-13 12:23:25 -04:00
Rob Rix
77ddc0abd8
Source spans are zero-indexed.
2016-09-13 12:23:05 -04:00
Rob Rix
b7d9ab1875
Add a trivial test of SourceSpan -> Range computation.
2016-09-13 12:09:18 -04:00
Rob Rix
076f5c0d1e
Stub in a spec for sourceSpanToRange.
2016-09-13 11:59:46 -04:00
Rob Rix
b5d14e702c
Test that actualLineRanges is exhaustive.
2016-09-13 11:56:43 -04:00
Rob Rix
04519db7a9
Verify that actualLineRanges produces the intended # of lines.
2016-09-13 11:39:27 -04:00
Rob Rix
8d5bc01a75
Run the Source spec.
2016-09-13 11:39:05 -04:00
Rob Rix
dcc164d09f
Add a spec for Source.
2016-09-13 11:35:10 -04:00
Rob Rix
2b34916554
Build and run RangeSpec 😔
2016-09-13 11:18:38 -04:00
joshvera
d3440439dc
Merge remote-tracking branch 'origin/master' into rws-large-diffs
2016-09-12 14:55:20 -04:00
joshvera
dbb687b33e
Split Term and Diff into SyntaxTerm and SyntaxDiff types as well
2016-09-09 14:51:20 -04:00
Rob Rix
8d955c3f96
Placate hlint.
2016-09-09 14:47:24 -04:00
Rob Rix
98637ad656
Generalize Term/TermF & Diff/DiffF over the functor.
2016-09-09 14:46:50 -04:00
joshvera
499f5da329
Export isBranchInfo and clean up some warnings
2016-08-25 12:22:58 -04:00
joshvera
17da45b320
Moved isBranchInfo to DiffSummary
2016-08-24 15:28:10 -04:00
joshvera
3b33c6860f
Update some test diffs
2016-08-22 10:33:42 -04:00
joshvera
9064e5f047
Fix up semantic-diff-tests
2016-08-22 10:33:26 -04:00
Rob Rix
7009d9ac2b
Move the multiple hunks fixture back to the main diffs list.
2016-08-18 15:33:14 -04:00
Rob Rix
00689650dd
Use the defaultFeatureVectorDecorator in the tests.
2016-08-18 14:03:36 -04:00
Rob Rix
d169e6fa66
Spacing.
2016-08-18 12:51:07 -04:00
Rob Rix
b14a7765e6
Copy in b.
2016-08-18 11:40:39 -04:00
Rob Rix
ecaff655c1
Extract a function to copy terms in.
2016-08-18 11:40:33 -04:00
Rob Rix
cabf1a887e
Compute recursive as copies instead of replacements.
...
This should make us more accurate to the tests of Interpreter.
2016-08-18 11:37:55 -04:00
Rob Rix
02bb72ee0b
Move compare to the where clause.
2016-08-18 11:25:21 -04:00
Rob Rix
8aa0f082a6
Bump _q_ in all of the specs.
...
Figure it’s best if they use the same value for the parameter.
2016-08-18 11:23:21 -04:00
joshvera
c09887b8df
update semantic-diff tests
2016-08-17 11:24:12 -04:00
joshvera
b4133bdcac
Map comma operators to flattened indexed nodes
2016-08-16 17:24:06 -04:00
Rob Rix
9dcbe04297
Move the multiple hunks fixture to the todo list.
...
See also #682 .
2016-08-12 13:43:00 -04:00
Rob Rix
e820b43469
🔥 a redundant import.
2016-08-12 13:40:41 -04:00
Rob Rix
b91b305f32
Re-enable the RWS insertion bias tests.
2016-08-12 13:22:55 -04:00
Rob Rix
443df7da7c
Merge branch 'unbiased-branch-diff-tests-that-actually-test-branch-diff-bias' into unbiased-branch-diffs
...
# Conflicts:
# src/Diffing.hs
# test/CorpusSpec.hs
# tools/semantic-git-diff/test/corpus/diff-summaries.json
2016-08-12 13:04:33 -04:00
Rob Rix
d9be26396c
Make the RWS test pending on #683 .
2016-08-12 12:58:37 -04:00
Rob Rix
2b35110d0a
🔥 the faulty tests of unbiased branch diffs.
2016-08-12 12:24:38 -04:00
Rob Rix
ff4861e2fb
Add the unbiased insertion test to the Interpreter spec.
2016-08-12 12:16:48 -04:00
Rob Rix
d3c333ae64
🔥 the faulty tests of unbiased insertions.
2016-08-12 11:59:44 -04:00
Rob Rix
b1e893b3f8
Add a concrete test of unbiased insertions.
2016-08-12 11:59:09 -04:00
Rob Rix
ada00d0485
The RWS unbiased tests require disjoint syntax constructors.
2016-08-12 11:44:29 -04:00
Rob Rix
5462278d0f
Use the replacing
combinator in the tests.
2016-08-12 11:44:23 -04:00
Rob Rix
bcaf909957
Revert "Mark the (failing) rws tests as pending for the time being."
...
This reverts commit a9025cacda01db216590e99dd36e867611e0f953.
2016-08-12 11:44:18 -04:00
Rob Rix
fa983e5561
Add a concrete test of unbiased deletions.
2016-08-12 11:40:30 -04:00
Rob Rix
2eead056e1
The RWS unbiased tests require disjoint syntax constructors.
2016-08-12 09:56:24 -04:00
Rob Rix
7bbbc4cbea
Use the replacing
combinator in the tests.
2016-08-12 09:53:16 -04:00
Rob Rix
0eb43f47a3
Use wrap
in the RWS correctness test.
2016-08-12 09:46:45 -04:00
Rob Rix
df25851902
Revert "Mark the (failing) rws tests as pending for the time being."
...
This reverts commit a9025cacda01db216590e99dd36e867611e0f953.
2016-08-12 09:13:52 -04:00
Rob Rix
73f73fdb40
Mark the (failing) rws tests as pending for the time being.
2016-08-11 15:24:02 -04:00
Rob Rix
86fd5b21fd
Use the replacing
smart constructor.
2016-08-11 14:42:17 -04:00
Rob Rix
0346b5d8f1
Use galign to ensure that the constructors are disjoint.
2016-08-11 14:32:10 -04:00
Rob Rix
0fc0e80ed9
Revert "Revert "Ensure that the syntaxes are disjoint.""
...
This reverts commit cfe27aec6f0764f451c493439086e03a1bdcf176.
2016-08-11 13:33:33 -04:00
Rob Rix
d9b48b6def
Revert "Ensure that the syntaxes are disjoint."
...
This reverts commit 43ebf52752a8cf22ae18633a5667966fd3f74aa0.
2016-08-11 13:28:51 -04:00
Rob Rix
70a622ca84
Ensure that the syntaxes are disjoint.
2016-08-11 13:27:45 -04:00
Rob Rix
fd23564dd5
Use a single root function for both interpreter tests.
2016-08-11 13:05:36 -04:00
Rob Rix
3eb05a31b1
Test the interpreter against insertions as well.
2016-08-11 13:03:22 -04:00
Rob Rix
fd2274b997
Use a single annotation for both children.
2016-08-11 13:00:54 -04:00
Rob Rix
261e82fd21
Extract a constructor for the root terms.
2016-08-11 12:54:14 -04:00
Rob Rix
7d8eb02ec8
Strip the diff and terms in the rws correctness test.
2016-08-11 12:50:56 -04:00
Rob Rix
3bb86389ed
Strip the diff in the replacement of unicode equivalent terms test.
2016-08-11 12:48:41 -04:00
Rob Rix
15b515e7a1
Strip the diff in the correctness test.
2016-08-11 12:48:27 -04:00
Rob Rix
336f37d0c8
Strip diffs in the unbiased test.
2016-08-11 12:45:40 -04:00
Rob Rix
0aef8a8467
Use stripDiff in the RWS spec.
2016-08-11 12:44:49 -04:00
Rob Rix
8d22e7bd85
Pointfree definition of root
.
2016-08-11 12:37:19 -04:00
Rob Rix
7bb5d7cd36
Use a single function to compute both roots.
2016-08-11 12:36:41 -04:00