15 Commits

Author SHA1 Message Date
Nathan Hawes
34098a75f5 [IDE][DocSupport] Fix DocInfo missing decls when generated for clang submodules.
Out handling of clang submodules was handled differently between DocInfo and
InterfaceGen. For InterfaceGen submodules were mapped back to their top-level
clang modules (or their Swift overlay if it had one) before being passed
into printSubmoduleInterface, along with the dot separated name of the submodule.

For DocInfo, they were not, and only the rightmost component of their name was
passed. The call to retrieve the decls from a ModuleDecl doesn't work if the
ModuleDecl wraps a clang submodule, so we were missing these decls.

InterfaceGen for submodules also shouldn't have been mapping the module back to
the overlay of top-level clang module, as that meant we ended up printing
import decls from the Swift overlay in the submodule's interface.

Resolves rdar://problem/57338105
2020-05-06 09:28:00 -07:00
Rintaro Ishizaki
aee280ad65 [SourceKit/Testing] Add %diff as an alias for 'diff --strip-trailing-cr' 2020-04-08 11:23:48 -07:00
Ben Langmuir
0b93a247c6 [test] Remove now-redundant %mcp_opt from sourcekit tests
Remove `%mcp_opt` from commands that use `%sourcekitd-test` and
`%complete-test`, as they are now redundant with the lit substitution.
2020-01-22 11:12:25 -08:00
Rintaro Ishizaki
0aa3125b62 [Testing] Eliminate REQUIRES-ANY usage
REQUIRES-ANY is deprecated and being removed. Use boolean expressions.

rdar://problem/58549266
2020-01-14 10:21:49 -08:00
Brent Royal-Gordon
f7eea0facd Disable swift_evolve for SourceKit tests
A lot of these are source-order-dependent and there’s no particular reason to think they’re relevant to resilience testing.
2018-12-18 16:26:35 -08:00
Brent Royal-Gordon
7a3ed15846 Exclude/fix certain tests for swift-evolve (#21276)
* Add swift_evolve feature and disable several tests

This change adds a swift_evolve feature to our lit configuration and uses it to mark several tests as unsupported by swift_evolve.

One of these—test/api-digester/stability-stdlib-abi.swift—is actually pretty bad; we would really like to have it. But the digester has known issues exposed by swift-evolve.

* Remove order dependency in another test

* Tweaks from Jordan’s review

* Distinguish between tests which are intentionally unsupported and temporarily disabled.
* Add an explanation for one unsupproted test.
* Code nitpick.
2018-12-13 14:26:47 -08:00
Ben Langmuir
368e25ec05 [sourcekit] Fix tests that depend on accepting frontend arguments
These tests were relying on sourcekitd parsing as frontend instead of
using the driver.  Update them now to avoid churn when we fix command
line argument parsing in sourcekit.

The changes from clang-importer-sdk to clang-importer-sdk-nosource -I %t
are because clang-importer-sdk implies using -enable-source-import.
Rather than hack them up to use -Xfrontend, it is cleaner to just stop
using source import at all for these tests.  Incidentally, this improved
fidelity in a few places.  When using the generated swift modules we
also need to pass a target triple to sourcekit, which exposed some tests
that had mac-specific data.  This is a systemic issue for sourcekit
tests, but for now just make those few specific tests that we had
problems with run only on mac.
2018-02-05 10:09:03 -08:00
Argyrios Kyrtzidis
9093dd7528 [test/SourceKit] Re-enable and update tests after recent stdlib changes
rdar://35799113
2017-12-05 10:23:14 -08:00
Ben Cohen
c481806339 XFAIL one more SourceKit unexpected difference test 2017-12-01 16:29:38 -08:00
Slava Pestov
9487a1e786 Update and un-XFAIL doc_clang_module test 2017-05-17 00:39:46 -07:00
Ben Cohen
ea2f64cad2 [stdlib] Add Sequence.Element, change ExpressibleByArrayLiteral.Element to ArrayLiteralElement (#8990)
* Give Sequence a top-level Element, constrain Iterator to match

* Remove many instances of Iterator.

* Fixed various hard-coded tests

* XFAIL a few tests that need further investigation

* Change assoc type for arrayLiteralConvertible

* Mop up remaining "better expressed as a where clause" warnings

* Fix UnicodeDecoders prototype test

* Fix UIntBuffer

* Fix hard-coded Element identifier in CSDiag

* Fix up more tests

* Account for flatMap changes
2017-05-14 06:33:25 -07:00
Brian Croom
98e3ca8bc4 Annotate some SourceKit tests that fail on Linux.
* A bunch of them require objc_interop because they import code containing
  Objective-C.
* Many others fail on Ubuntu 14.04 because the C++ there doesn't have a
  functional std::regex implementation which is required by the
  `complete-test` tool.

It may be possible to adjust some of these tests in the future to not
need these extra requirements, but this is a straightforward way to
clean up Linux test results for now.
2016-06-14 08:55:48 -04:00
Dmitri Gribenko
d5157c85da Fix test SourceKit/DocSupport/doc_clang_module.swift 2016-06-09 07:57:28 -07:00
Arnold Schwaighofer
f9e1d53523 Disable failing test for now
This started failing after one of the two commits:

[stdlib] Add missing discardableResult attribute
Fixes SR-1695: Option Set insert needs @discardableResult

[gardening] Remove unused diagnostic
attr_warn_unused_result_mutable_variable

These commits seem harmless so I disabled the test pending further
investigation.

rdar://26718415
2016-06-09 07:09:18 -07:00
Argyrios Kyrtzidis
8ff6a98a99 [sourcekit] Merge SourceKit into the Swift repo.
The code goes into its own sub-tree under 'tools' but tests go under 'test',
so that running 'check-swift' will also run all the SourceKit tests.

SourceKit is disabled on non-darwin platforms.
2015-11-05 01:09:08 -08:00