Commit graph

1422 commits

Author SHA1 Message Date
Justin Goshi
2cc4f3f166 Merge branch 'rel/1.0.0' into dev/jgoshi/handleDeprecatedPJ 2017-01-26 14:28:37 -08:00
Justin Goshi
3821d39d6c Address PR comments 2017-01-26 12:53:29 -08:00
Livar Cunha
40c0c41cde Handling a potential race condition when writing global.json during migration. 2017-01-26 12:40:56 -08:00
Livar Cunha
537d78d2a6 Fixing test failures. One of them, is a known issue that still reproes intermittently. The other was some left over code that was causing problems. 2017-01-26 12:40:56 -08:00
Livar Cunha
85ec8a6f2c Fixing our solution tests so that they go back to building the solution. Seems to work now, at least on OSX. Also, made a change to update solution to update any solutions in the folder where dotnet migrate is executed. 2017-01-26 12:40:55 -08:00
Eric Erhardt
fafc2eedae Work around ZipArchive bug in tests
See https://github.com/dotnet/corefx/issues/15516, 'dotnet' executable doesn't get its execute flag set in netcoreapp2.0.
2017-01-26 13:18:41 -06:00
Justin Goshi
037da3fc01 Finish tests 2017-01-26 11:00:50 -08:00
Justin Goshi
61ae452fe2 Updating tests 2017-01-26 09:55:09 -08:00
Justin Goshi
8b7c0ad468 Add more tests 2017-01-26 09:15:30 -08:00
Krzysztof Wicher
ecd034b95c fix build errors after rebase 2017-01-26 09:02:28 -08:00
Krzysztof Wicher
000734d1ef Ignore explicit glob **/*.cs 2017-01-26 09:02:28 -08:00
Justin Goshi
ddf3261a67 Add more tests 2017-01-26 08:34:36 -08:00
Eric Erhardt
eefdbb8846 Disable test due to crossgen bug https://github.com/dotnet/coreclr/issues/9118. 2017-01-26 10:05:11 -06:00
Eric Erhardt
d4153815d5 Update the CLI to netcoreapp2.0. 2017-01-26 07:28:59 -06:00
Justin Goshi
150e3c4313 Add more tests 2017-01-25 17:28:57 -08:00
Justin Goshi
b8d4010d85 Handle some of the deprecated properties 2017-01-25 12:30:56 -08:00
Justin Goshi
731ab92c1f Update the test 2017-01-24 10:57:07 -08:00
Piotr Puszkiewicz
7c62621b8f Merge branch 'rel/1.0.0-rc3' into rel/1.0.0-rc3 2017-01-24 03:07:49 -08:00
Piotr Puszkiewicz
ad8710decc SDK 20170123-1 (#5434)
* Revert "Merge pull request #5362 from dotnet/ragrawal/updatesdktrial"

This reverts commit 4e0b465093.

* bump SDK to 20170123-1
2017-01-24 01:14:35 -08:00
Mike Lorbetske
872e96cfe2 Update version of Microsoft.AspNetCore.Mvc 2017-01-23 20:21:58 -08:00
Justin Goshi
a2088e2641 Refactor and finish the feature 2017-01-23 13:01:58 -08:00
Justin Goshi
3884c90938 Merge from rel/1.0.0 2017-01-23 10:25:16 -08:00
Piotr Puszkiewicz
1dfee9ead8 [WIP] Reduce test target complexity [and running time] (#5403)
* Reduce test target complexity [and running time]

* WiP

* Enable building tests via solution

Remove deprecated tests
Make Microsoft.DotNet.Tools.Tests.Utilities portable-only
Remove MSI tests from the solution as they are the only  tests that currently require dekstop.

* Enable building of tests

* Move migration tests to TA to allow them to self-restore

* Reduce project nesting and test directory name
2017-01-22 14:40:00 -08:00
Dustin Campbell
0a62481cc0 Create backup folder in the directory where 'dotnet migrate' is executed (#5306)
* Create backup folder in the directory where 'dotnet migrate' is executed

With this change, 'dotnet migrate' will create the backup folder in the workspace directory rather
than the parent of the workspace directory. This solves two problems:

1. It makes it easier for the user where the backup is -- it's in the directory they targeted with
'dotnet migrate'.
2. It solves a problem of file oollisions with global.json files when migrating multiple projects.
Consider the following directory structure:

    root
        |
        project1
            |
            global.json
            |
            src
                |
                project1
        project2
            |
            global.json
            |
            src
                |
                project2

    Prior to this change, running 'dotnet migrate' project1 and then running it again in project2
    would have caused an exception to be thrown because the migration would try to produce a backup
    folder like so:

    root
        |
        backup
        |  |
        |   global.json
        |   |
        |   project1
        |   |
        |   project2
        |
        |
        project1
            |
            src
                |
                project1
        project2
            |
            src
                |
                project2

    Now, we produce the following structure, which has no collisions:

    root
        |
        project1
            |
            backup
            |   |
            |   global.json
            |   |
            |   project1
            |
            src
                |
                project1
        |
        project2
            |
            backup
            |   |
            |   global.json
            |   |
            |   project2
            |
            src
                |
                project2

In addition, to help avoid further collisions, a number is appened to the backup folder's name if
it already exists. So, if the user runs dotnet migrate again for some reason, they'll see backup_1,
backup_2, etc.

* Fix test helper

* Fix foolish bug causing infinite loop

* Fix up a couple more tests

* Rework MigrationBackupPlan to process all projects at once

* Fix up tests

* Still fixing tests

* Compute common root folder of projects to determine where backup folder should be placed

* Fix typo

* Fix test to not look in backup folder now that it's in a better location
2017-01-21 01:58:28 -08:00
Piotr Puszkiewicz
04a7fca9fc Fixing argument parsing in add package command (#5421)
* Fixing argument parsing in add package command

* Adding check to throw if extra args were passed

* Removing string and adding test cases for dotnet add package command

* Add new test to test.sln, and fix naming, and clean csproj
2017-01-21 00:11:18 -08:00
Justin Goshi
b2c51b7269 Do not add duplicate solution folders or project directories (#5377)
* Do not add duplicate solution folders or project directories

* Fix the algorithm for removing empty solution folders

* Improving code by adding description methods. To address PR comments.
2017-01-20 18:34:37 -08:00
Justin Goshi
baecbd8d43 WIP 2017-01-20 17:37:11 -08:00
Piotr Puszkiewicz
fe290f1e26 Merge branch 'rel/1.0.0' into dev/jgoshi/issue5343 2017-01-20 14:08:49 -08:00
Piotr Puszkiewicz
26aa05cfea Merge pull request #5394 from livarcocc/migrate_global_json
Handle dotnet migrate global.json
2017-01-20 14:07:27 -08:00
Justin Goshi
33c962a481 Merge branch 'rel/1.0.0' into dev/jgoshi/issue5343 2017-01-20 12:21:43 -08:00
Justin Goshi
717d0a45fa Moving existing csproj files with same name as migration output to backup 2017-01-20 12:21:04 -08:00
Livar
870f7edc87 Merge branch 'rel/1.0.0' into migrate_sln 2017-01-19 18:42:00 -08:00
Piotr Puszkiewicz
dd59e2ce97 Merge pull request #5130 from blackdwarf/slntest
Introducing solution file for test projects
2017-01-19 16:12:38 -08:00
Livar Cunha
dbf4b5de77 Adding a test that verifies that running dotnet migrate solution.sln will only migrate the projects in the solution file. 2017-01-19 13:59:31 -08:00
Justin Goshi
56c3010f72 Merge branch 'rel/1.0.0' into dev/jgoshi/issue5343 2017-01-19 13:17:05 -08:00
Livar
c4e2c35d25 Merge branch 'rel/1.0.0' into migrate_global_json 2017-01-19 12:25:35 -08:00
Livar Cunha
7f4273d4b1 Adding one more test to ensure that migrate global.json will continue to target only projects under the global.json's project node. 2017-01-19 12:24:42 -08:00
Justin Goshi
5bbac55736 Migration: do not add a csproj to the solution if it already exists 2017-01-19 11:23:01 -08:00
Livar Cunha
cdf91f2f30 Fixing dotnet migrate global.json. This was failing because we were turning global.json into an empty string and trying to construct a directory for it. The fix was to detect this and transform it into a . directory. Migrate is already respecting the projects node in global.json. 2017-01-19 10:55:23 -08:00
Piotr Puszkiewicz
05956f6efa Merge branch 'rel/1.0.0-rc3' into ragrawal/updatesdktrial 2017-01-18 13:41:50 -08:00
Krzysztof Wicher
1a20d7f82c Merge remote-tracking branch 'github/rel/1.0.0-rc3' into rel/1.0.0 2017-01-18 12:38:11 -08:00
Zlatko Knezevic
0ce6b0cc0f Merge branch 'rel/1.0.0' into slntest 2017-01-17 21:12:11 -08:00
Justin Goshi
a5fb786228 Ensure we don't downgrade VS version 2017-01-17 14:48:54 -08:00
Justin Goshi
2676682fec Migrate should change the visual studio version 2017-01-17 13:45:48 -08:00
Livar Cunha
2161364116 Adding a test for a project that has a package dependency whose name is also the name of a folder in the repo.
Moved the test to dotnet-migrate.Test and modified the code that find possible P2P dependencies to actually check if the folder holds a project.
2017-01-17 13:14:18 -08:00
Zlatko Knezevic
d93b7abca0 Merge branch 'rel/1.0.0' into slntest 2017-01-17 12:53:44 -08:00
Rohit Agrawal (NUGET)
337d579949 update nuget and sdk to run a trial build 2017-01-17 11:08:17 -08:00
Livar
557999a5bd Merge pull request #5352 from livarcocc/skip_project_references
Skipping project dependencies check when the skip-project-references flag is passed
2017-01-16 16:20:39 -08:00
Livar Cunha
e1f355065d Moving the project dependencies construction to after we check for the skip project reference check, so that we really don't look for P2P projects when the flag is passed. 2017-01-16 15:16:31 -08:00
Livar Cunha
b8da3b9a87 Updating the versions of xunit 2.2.0-beta5-build3474 and xunit runner to 2.2.0-beta5-build1225. 2017-01-16 13:08:40 -08:00
Zlatko Knezevic
632a6f0ce7 Fixing build breaks 2017-01-13 14:14:12 -08:00
Livar Cunha
8c2e7c9f01 Merge branch 'rel/1.0.0-rc3' into merge_rc3
* rel/1.0.0-rc3:
  Fixing an issue where packages with a filter but no match were not being migrated as is, instead they were being dropped.
  Add support for migrating Microsoft.AspNetCore.Mvc.ViewCompilation
  Switching to using a csv as the source of our lts packages. Also, this is a more comprehensive list.
  Adding a few more packages that were not in the manifest and moving some tests around.
  Migrating packages to LTS (1.0.3) versions if they have a smaller version than the LTS one.
  Adding ranges to the source mappings so that we can specify the origin should match this range and migrate to that version. We use this to handle LTS/FTS migration and will use that for the LTS uplift.
  Migration: do not inject built in compile includes that the SDK does
  Update msbuild to 15.1.0-preview-000522-02
  Migration: Do not add RIDs for Library projects (#5279)
  Use a separate env variable to control uploading the lzma archive. We only want OSX to publish the archive, because turns out that windows published archives are not used by unix based oses.
  Fix the download of the LZMA archive on dev machines and in Jenkins CI.
2017-01-13 14:08:31 -08:00
Piotr Puszkiewicz
968ee5c3f6 Merge branch 'rel/1.0.0' into slntest 2017-01-13 11:19:47 -08:00
Justin Goshi
f972cf80a9 Treat /? the same as --help (#5285)
* Fixes issue 4539

* Support -?
2017-01-13 01:24:12 -08:00
Zlatko Knezevic
75dc96be2a Merge branch 'rel/1.0.0' into slntest 2017-01-12 23:00:41 -08:00
Livar Cunha
18a3dd60b5 Fixing an issue where packages with a filter but no match were not being migrated as is, instead they were being dropped. 2017-01-12 18:23:35 -08:00
Krzysztof Wicher
5fea7c3ae6 Remove try catches choking all exceptions (#5206)
* remove some try catches choking all exceptions

* rename ExceptionExtension to ReportAsWarning, show full stack instead of just message

* dotnet-migrate try catch clean-up

* fix migration test failures
2017-01-12 15:42:36 -08:00
Livar
a9c5f4e90a Merge pull request #5293 from dotnet/dev/jgoshi/issue5253
Migration: do not inject built in compile includes that the SDK does
2017-01-12 15:00:03 -08:00
Pranav K
80c435e6a1 Add support for migrating Microsoft.AspNetCore.Mvc.ViewCompilation 2017-01-12 13:49:28 -08:00
Livar Cunha
deb50a3cc7 Switching to using a csv as the source of our lts packages. Also, this is a more comprehensive list. 2017-01-12 11:38:05 -08:00
Livar Cunha
12abcf7208 Adding a few more packages that were not in the manifest and moving some tests around. 2017-01-12 11:38:05 -08:00
Livar Cunha
a0aa8150de Migrating packages to LTS (1.0.3) versions if they have a smaller version than the LTS one. 2017-01-12 11:38:05 -08:00
Livar Cunha
89fba856e8 Adding ranges to the source mappings so that we can specify the origin should match this range and migrate to that version. We use this to handle LTS/FTS migration and will use that for the LTS uplift. 2017-01-12 11:38:05 -08:00
Justin Goshi
71da7f6a45 Migration: do not inject built in compile includes that the SDK does 2017-01-12 11:22:41 -08:00
Piotr Puszkiewicz
c0b73e4b5f Merge branch 'rel/1.0.0' into slntest 2017-01-11 17:37:46 -08:00
Piotr Puszkiewicz
0f9888c11d Merge branch 'rel/1.0.0' into piotrpMSFT/merge/rc3toRTM 2017-01-11 17:15:44 -08:00
Krzysztof Wicher
c9b873caad make dotnet-build show build summary (#5277)
* make dotnet-build show build summary

* Fix race in some dotnet-migrate (sln) tests
2017-01-11 17:06:03 -08:00
Justin Goshi
03be0e56d4 Migration: Do not add RIDs for Library projects (#5279)
* WIP

* Do not add runtime identifiers for libraries

* Reusing an existing test project

* Fix up tests
2017-01-11 17:05:12 -08:00
PiotrP
9008aaff85 merge RC3 into rel/1.0.0 2017-01-11 13:03:09 -08:00
Livar
4b82852d56 Updating the version of msbuild to 15.1.0-preview-000516-03 (#5266)
* Updating the version of msbuild to 15.1.0-preview-000516-03

* Remove test that assumes props/targets imports

The test ItAddsRefBetweenImports validated that the MSBuild XML model contained new project references between the props and targets imports. While useful be fore the SDK attribute, the test no longer adds value since the SDK is added implicitly, guaranteeing it wraps the remaining project contents.

* Move MSBuild to 15.1.0-preview-000509-03

This is the last msbuild version prior to the change of MSBuild's dependencies to include .NET 1.1 components.

* Move MSBuild invocations to use dirs.props/dirs.tasks

* Put back the test targets. We'll unify later.

* Remove dirs.props props from templates msbuild invocation
2017-01-11 01:49:22 -08:00
Piotr Puszkiewicz
19f18a291f Merge branch 'rel/1.0.0' into slntest 2017-01-11 01:17:52 -08:00
Mike Lorbetske
ad6fab0a15 Synchronize templates with new3, add global.json (#5244)
* Synchronize templates with new3, add global.json

* Add runtimeconfig.template.json for web

Removes global.json write during template creation

* Remove global.json check from the test

* making templates the same as new3 templates

* Fix broken PrivateAssets, content update

Sets OutputType as appropriate
Alphabetizes package references

* Rollback browserlink version to 1.0.0

* Downgrade 1.1.0 of browserlink to 1.0.0 as well

* Add newline to the end of the console project
2017-01-10 22:58:30 -08:00
Eric Erhardt
5035320247 Add NuGet version to DependencyVersions.props. 2017-01-10 10:43:14 -06:00
Livar
87e9815a25 Merge pull request #5234 from harshjain2/tpv2update
Updated version of Test Platform
2017-01-07 14:44:01 -08:00
Harsh Jain
ce64bee309 updated veersion of Microsoft.NET.Test.sdk for failing tests. 2017-01-08 03:01:58 +05:30
Livar
f2f37729b8 Merge pull request #5235 from eerhardt/PopulateNuGetCache11
Populate nuget cache for shared fx and asp.net 1.1
2017-01-07 11:31:54 -08:00
Eric Erhardt
10f70dd034 Add a test to ensure 1.0 and 1.1 packages are available in the nuget cache on first run. 2017-01-07 08:43:28 -06:00
Rohit Agrawal
5bbfbfeeed update nuget to 4.0.0-rc3 and sdk to 1.0.0-alpha-20170105-5 (#5214)
* update nuget to 4.0.0-rc3 and sdk to 1.0.0-alpha-20170105-5

* Modifying restore project.json to use the project.json stage0 CLI instead of restore-projectjson command.

* add a nuget dependency so migrated project has packageref and generates an assets file on restore
2017-01-06 16:28:04 -08:00
Eric Erhardt
0cfc54c377 First time experience populating the NuGet cache with 1.1 packages. 2017-01-06 17:45:34 -06:00
Krzysztof Wicher
7042e85292 dotnet list p2ps -> dotnet list reference 2017-01-06 14:58:38 -08:00
Krzysztof Wicher
528d37bda5 dotnet remove p2p -> dotnet remove reference 2017-01-06 14:58:38 -08:00
Krzysztof Wicher
3ad9b72664 dotnet add p2p -> dotnet add reference 2017-01-06 14:58:38 -08:00
Livar
5bdbe354b2 Merge pull request #5226 from livarcocc/migrate_full_framework
Migration will now pick win7-x86 as the RuntimeIdentifier to be used by Full Framework TFMs
2017-01-06 14:48:35 -08:00
Mike Lorbetske
decec5f8da First step to ingest template engine (#5065)
* First step to ingest template engine

Please do not merge yet
@piotrp @seancpeters @livarocc

* Localization

* Attempt to get a build going

Rename program.cs to New3Command.cs
Move TableFormatter into its own file
Consume template engine packages version 1.0.0-beta1-20161218-24
Temporarily add MyGet templating feed so that package restore will work

* Update ExtendedCommandParser

Make short form args prefer longer runs of characters in the source
parameter before falling back to p:shortname syntax
Change scoping for a few methods to get rid of inconsistent visiblity
errors

* Fix package installation wildcards

* Cleanup New3Command, fix review issue, bump version, sorting for template list

* Installation, loc fix, help formatting

* Use latest TemplateEngine packages

* New3 unit tests

* Fixed formatting on csproj files

* Add the build steps to add templates to the layout

* Change tests slightly to make comparisons easier

Also fixes the wrong flag getting passed to set language

* Fixes for 127, 128, 130, 131 - help display

* Sync to latest TemplateEngine version

Absorbs new search logic

* All tests passing

Cleaner New3Command
Support for project/item template contexts

* Try to make tests more durable

* Disable test parallelization for dotnet-new tests

* Update web SDK and template engine versions

* Remove AI package feed

* Simplify CLI interface to Template Engine

* Fix host identifier and update to latest packages

* Update template engine & Web SDK versions

* Fix template engine version

* Remove UsingTask and redeclaration of property
2017-01-06 14:48:27 -08:00
Justin Goshi
e109a9be47 dotnet sln command (#5233)
* Add dotnet sln command

* Use new names for localizable strings

* Fix up the tests for the verb rename
2017-01-06 10:58:23 -10:00
Livar Cunha
0ebb92f3c4 Renaming a test asset to avoid running into long path issues on Windows. 2017-01-06 11:34:37 -08:00
Piotr Puszkiewicz
bf4588b6fc Add PJ support to TestAssets (#5109)
* Add PJ support to TestAssets

* Cleaning the test assets is hard, so throwing instead

* better assets filter

* PR feedback

* PR Feedback

* Fix NullRef

* Move lock to surround action + file read/write
2017-01-06 01:40:26 -08:00
Livar
b5991909fb Merge pull request #5227 from livarcocc/update_cli_no_implicit
Updating our projects and test assets to work with the latest SDK.
2017-01-05 23:04:17 -08:00
Livar Cunha
7e5f18b584 Fixing full framework tests. 2017-01-05 22:55:43 -08:00
Livar
7bcffe9e82 Merge pull request #5222 from blackdwarf/slnlocstrings
Adding strings for dotnet-sln command for LOC
2017-01-05 22:07:48 -08:00
Livar Cunha
b41eb43883 Updating our projects and test assets to work with the latest SDK. 2017-01-05 19:44:52 -08:00
Livar Cunha
abe7641f03 Migration will now pick win7-x86 as the RuntimeIdentifier to be used by Full Framework TFMs when no RIDs exist in the source PJ. This will allow build/publish etc to continue working in csproj without extra RIDs parameters in the command line. 2017-01-05 16:52:02 -08:00
Livar
80f2ef6533 Merge pull request #5181 from harshjain2/clirunsettings
Added ability to pass runsettings as commandline parameters after --
2017-01-05 16:22:08 -08:00
Zlatko Knezevic
ab41acd8f5 Adding strings for dotnet-sln command for LOC
Adding strings both in the command folder as well as in the Help command.
2017-01-05 14:44:53 -08:00
Justin Goshi
f8de8d5a80 dotnet add uses ProjectTypeGuid or DefaultProjectTypeGuid (#5218)
* dotnet add uses ProjectTypeGuid or DefaultProjectTypeGuid

* Create ProjectInstanceExtensions per PR comments
2017-01-05 12:04:57 -10:00
Livar
8effe48566 Merge pull request #5212 from livarcocc/update_sdk_with_globbing
Updating the SDK to an SDK that includes globing for source and resources
2017-01-05 13:49:32 -08:00
Livar
bf47363a5f Merge pull request #5219 from livarcocc/remove_define_constants_release
Adding Release to the sdk defined constants so that we don't emit it anymore
2017-01-05 12:46:56 -08:00
Livar Cunha
92ee4aac26 Pinning the CLI version because once this goes in, the next stage0 won't allow for having compile in the csprojs. We will have to update the CLI ones. 2017-01-05 12:31:49 -08:00
Livar Cunha
3a4e23e373 Updating the SDK to an SDK that includes globing for source and resources implicitly. 2017-01-05 12:31:48 -08:00
Krzysztof Wicher
dfb0a28224 Merge pull request #5180 from krwq/5070b
Remove some cross project compile includes on cs files
2017-01-05 12:13:54 -08:00
Livar Cunha
69e963669f Adding Release to the sdk defined constants so that we don't emit it during migration anymore. 2017-01-05 11:46:02 -08:00
Harsh Jain
f04930658d Merge branch 'rel/1.0.0' into clirunsettings 2017-01-06 01:15:49 +05:30
Eric Erhardt
639d467c14 Merge pull request #5210 from eerhardt/UpdateSharedFx103
Update Microsoft.NETCore.App to 1.0.3.
2017-01-05 12:06:57 -06:00
Eric Erhardt
75786cd59a Fixing It_adds_fx_version_as_a_param_when_the_tool_has_the_prefercliruntime_file test to expect 1.0.3. 2017-01-05 09:43:02 -06:00
Eric Erhardt
a80e8fa636 Update Microsoft.NETCore.App to 1.0.3. 2017-01-05 08:57:53 -06:00
Livar
fa52ea9d18 Merge pull request #5200 from livarcocc/remove_condition_tfm_for_single_tfm
Remove condition tfm for single tfm
2017-01-04 22:19:19 -08:00
Harsh Jain
6e9e5baa83 Merge branch 'rel/1.0.0' into clirunsettings 2017-01-05 10:25:53 +05:30
Justin Goshi
d0151a6111 Add/remove solution items based on directory structure (#5197)
* WIP support solution folders for dotnet add and remove

* Add/remove solution folders based on directory hierarchy

* Fix tests

* Disable the solution building tests

* Address PR comments

* Fix a build break due to a new tool version used in the build

* Create SlnProjectExtensions and SlnProjectCollectionExtensions per PR comments
2017-01-04 18:32:09 -10:00
Livar Cunha
a4dcff9ea8 Addressing code review comments. 2017-01-04 12:25:48 -08:00
Harsh Jain
71027cda33 Merge branch 'rel/1.0.0' into clirunsettings 2017-01-05 00:53:41 +05:30
Livar Cunha
47eafb9ef4 Removing the PackageTargetFallback condition on TFM when there is only a single TFM 2017-01-03 20:36:51 -08:00
Livar Cunha
e9561b3679 Removing the IsCrossTargetBuild from migrated scripts when there is only a single TFM 2017-01-03 17:15:39 -08:00
Justin Goshi
281eca2f8c Disable tests that fail sporadically (#5192) 2017-01-03 11:06:51 -10:00
Justin Goshi
19b4bad315 Add/remove projects also updates build configurations (#5134)
* Add/remove projects also updates build configurations

* Fix the algorithm for adding/removing build configurations

* Address PR comments
2017-01-03 07:18:45 -10:00
Harsh Jain
473d3cca37 Merge branch 'rel/1.0.0' into clirunsettings 2017-01-02 19:54:31 +05:30
Livar
06d33f01ce Merge pull request #5178 from livarcocc/update_tools_msbuild3
Updating the migrated tools version to 1.0.0-msbuild3-final.
2016-12-30 13:16:29 -08:00
Harsh Jain
19d919a640 Added method GetSemiColonEscapedArgs 2016-12-30 15:47:15 +05:30
Harsh Jain
245727183c Handling both mstest args and runsettings options after -- 2016-12-30 15:34:00 +05:30
Harsh Jain
8d86e14d44 Added support for passing runsettings options through command line after -- 2016-12-30 11:27:37 +05:30
Krzysztof Wicher
941575d188 Remove cross project compile include on DotnetFiles.cs 2016-12-29 14:34:24 -08:00
Justin Goshi
10f52d9a15 Improve error messages for why a solution failed to load (#5176)
* WIP Improve sln reader/writer error messages

* Added more tests

* Fix a few tests
2016-12-29 09:21:55 -10:00
Krzysztof Wicher
961905a301 Merge pull request #5158 from krwq/i5070
Fix #5071: Eliminate some cross project dependencies in tests and fix local builds on windows
2016-12-28 23:26:51 -08:00
Livar Cunha
24b5e00d14 Updating the expected versions in the tests for the test sdk and the test adapter and framework. 2016-12-28 23:13:02 -08:00
Livar Cunha
1f3356b330 Copying the nuget.config template for the publish web app test, so that the new tools packages can be resolved. 2016-12-28 22:03:18 -08:00
Livar Cunha
fa675cb5e5 Updating the migrated tools version to 1.0.0-msbuild3-final. 2016-12-28 21:26:31 -08:00
Livar
a1a30e35a1 Merge pull request #5174 from livarcocc/no_transitive_dependency_migration
Stopped doing hoisting of transitive project dependencies and references
2016-12-28 20:24:12 -08:00
Krzysztof Wicher
efe1b7b143 fix local build and ci build failures 2016-12-28 14:50:34 -08:00
Livar Cunha
ad88058266 Stopped doing hoisting of transitive project dependencies and references. We also don't validate if a dependency exist, since migration strictly speaking does not need it. We move the project.json and the csproj will fail to build just like the project.json would. 2016-12-28 14:48:38 -08:00
Justin Goshi
35f2192f3b Improve Sln reader/writer tests (#5157)
* WIP improve sln reader/writer tests

* Complete the tests
2016-12-28 09:40:49 -10:00
Satya Madala
05df71825d Testplatform release 15.0.0-preview-20161227-02 (#5055)
* Update testplatform packages version

* Refer TestPlatform version from DependencyVersions.props

* Updating the packages with respect to Testplatform release 15.0.0-preview-20161227-02

* Add dit.props to test assets projects
2016-12-28 10:17:33 -08:00
Krzysztof Wicher
e9dc08eafa make localizablestrings internal again 2016-12-27 14:53:45 -08:00
Krzysztof Wicher
88e7f0f593 remove cross project reference from dotnet-remove-p2p (and fix local failures) 2016-12-27 14:53:45 -08:00
Krzysztof Wicher
35bc8e1cc1 remove cross project reference from dotnet-add-p2p tests 2016-12-27 14:53:44 -08:00
Krzysztof Wicher
5095981ec3 fix line endings related errors in dotnet-add-p2p tests 2016-12-27 14:53:44 -08:00
Justin Goshi
b72d625168 Include ASP packages in offline cache (#5124)
* Archive asp.net package references

* Archive asp.net package references

* Change the hash input so it's the same on all platforms

* Address PR comments
2016-12-27 11:28:24 -10:00
Zlatko Knezevic
116ed9bca6 Introducing solution file for test projects
This commit introduces a solution file for test projects and modifies
the needed build targets to restore the test solution instead of each
test project separately.

It also introduces a new template called "sln" to dotnet new that drops
a template solution file for users to consume.

Fixes #5099
2016-12-22 09:47:19 -08:00
Livar
b4ef34bc38 Merge pull request #5104 from livarcocc/update_sdks
Updating the projects files in the repo to use the SDK attribute.
2016-12-21 15:34:33 -08:00
Livar Cunha
64360cb08b Commenting out building solution step in migrate tests because we have an issue in the SDK for it. 2016-12-21 14:06:06 -08:00
Jon Sequeira
3b0a2f5d20 Merge pull request #5106 from jonsequitur/make-migration-backup-folder-peer-of-project
make migration backup folder a sibling of the project root
2016-12-21 12:12:11 -08:00
Krzysztof Wicher
a65d857f73 Merge pull request #5102 from krwq/i1494tools
fix tools when restoring with --packages
2016-12-20 18:20:25 -08:00
jonsequitur
a145c7ae81 fix path length problem in test 2016-12-20 18:17:36 -08:00
Livar
10a1695d6c Merge pull request #5090 from livarcocc/migrate_app_config
Emitting a None item for App.config if one exists side-by-side to the project.json
2016-12-20 16:43:24 -08:00
Livar Cunha
3b081316ad Updating the SDK version in the BundleSdks.props and adding dirs.props back to all csprojs but the TestAssets ones. 2016-12-20 16:38:04 -08:00
Livar Cunha
fadacc0aac Updating the projects files in the repo to use the SDK attribute. 2016-12-20 15:52:50 -08:00
Jon Sequeira
35e3625d4b Merge branch 'rel/1.0.0' into make-migration-backup-folder-peer-of-project 2016-12-20 15:24:33 -08:00
Justin Goshi
89f0b05958 Improve sln migration tests (#5066)
* WIP Improve sln migration tests

* Simple migration test

* Improve the test

* WIP update test assets

* Update test

* Test a bug fix

* Add another migrate sln test

* Fix FilePath related tests

* Finish the migrate sln tests

* Fix tests

* Fix another path issue
2016-12-20 13:04:01 -10:00
Krzysztof Wicher
aa7fb60d73 remove redundant packagesRoot path check and reorder methods 2016-12-20 14:56:21 -08:00
Livar Cunha
4bda166b2f Emitting a None item for App.config if one exists side-by-side to the project.json. 2016-12-20 14:42:31 -08:00
jonsequitur
620e573f95 make migration backup folder a sibling of the project root 2016-12-20 14:35:52 -08:00
Krzysztof Wicher
444dd6a031 shorten random package name, address pr feedback 2016-12-20 13:53:21 -08:00
Krzysztof Wicher
59ae0e2d3d fix tools when restoring with --packages 2016-12-20 12:18:55 -08:00
Zlatko Knezevic
b467d66182 Remove argument separator from commands (#5080)
* Remove argument separator from commands

Currently, the argument separator (`--`) is only supported on
`dotnet run`. This PR removes it from other commands to make the help and
usage of these command clearer.

* Adding dotnet run message test

* Responding to PR feedback
2016-12-19 22:11:39 -08:00
Krzysztof Wicher
2d5e40f3ba Merge pull request #5085 from krwq/i5019
Add error message when tool is ivoked but not restored
2016-12-19 16:51:14 -08:00
Livar
134e9af798 Merge pull request #5078 from livarcocc/preserve_rids_from_pj
Only adding rids for full framework TFMs if the project.json does not have runtimes
2016-12-19 16:20:12 -08:00
Krzysztof Wicher
ccfb4135c4 Add error message when tool is not restored 2016-12-19 14:12:04 -08:00
Livar
2aa166b5d0 Merge pull request #5069 from livarcocc/version_attributes
Making version an attribute for packagereference and dotnetclitoolreference
2016-12-19 09:48:00 -08:00
Livar Cunha
b2ce6c794a Only adding rids for full framework TFMs if the project.json does not already have Runtimes in its Runtimes section. 2016-12-18 18:45:35 -08:00
Krzysztof Wicher
476a83eb1a Ensure dotnet restore --packages is working (#5008)
* add dotnet restore --packages tests

* add dotnet build, publish, pack, dotnet-test test

* Shorten the test name in attempt to fix test failure

* fix whitespaces
2016-12-18 00:45:25 -08:00
Livar Cunha
52b45d0c49 Fixing tests and a couple of issues in the code due to Localization. 2016-12-16 23:59:58 -08:00
Piotr Puszkiewicz
2a612f88af https://github.com/dotnet/cli/issues/5070 2016-12-16 22:45:48 -08:00
Scott Addie
e25e387f1f Add hyphen in Welcome to .NET Core Telemetry paragraph - commandline 2016-12-16 22:45:47 -08:00
Livar Cunha
ee999ef874 Adding clean to the expected help output. 2016-12-16 20:14:33 -08:00
Livar Cunha
612da09a78 Fixing the failing dotnet --help test. 2016-12-16 19:16:38 -08:00
Livar Cunha
e1c0bbe0f7 Making version an attribute for packagereference and dotnetclitoolreference. 2016-12-16 19:13:37 -08:00
Livar
9c3141b63f Merge pull request #5057 from dotnet/dev/jgoshi/removeProj
Implement dotnet remove project
2016-12-16 18:56:28 -08:00
Livar
e491fbdcd0 Merge pull request #5054 from codito/fix-retcode
Return non-zero exit code for test failure in multitargeted test project
2016-12-16 18:08:12 -08:00
Livar
a9ca6d8c5b Merge pull request #5062 from livarcocc/clean_empty_targets_migration
Added a clean empty targets method to CleanOutputProjectRule
2016-12-16 18:07:37 -08:00
Livar
f1c16e59d6 Merge pull request #5043 from livarcocc/d_for_diagnostics
Changing the host verbosity flag to -d|--diagnostics
2016-12-16 16:05:02 -08:00
Justin Goshi
e94748f172 Update tests for non-windows platforms 2016-12-16 15:25:07 -08:00
Justin Goshi
45264edcd7 Merge branch 'rel/1.0.0' into dev/jgoshi/removeProj 2016-12-16 14:53:33 -08:00
Livar Cunha
2336cd7aa0 Fixing the help message. 2016-12-16 14:31:53 -08:00
Livar
af3cab66f4 Merge pull request #5034 from livarcocc/duplicate_resource_migration
Adding a Exclude @(EmbeddedResource) during migration to EmbeddedResources
2016-12-16 14:26:07 -08:00
Livar Cunha
d6d6fc612b Added a unit test for cleaning empty targets.
Added a clean empty targets method to CleanOutputProjectRule that removes any targets without content inside of them from the csproj.
2016-12-16 13:31:42 -08:00
Livar Cunha
9fd4903bf3 Addressing code review comments and adding a test for dotnet --help. 2016-12-16 12:58:34 -08:00
Livar Cunha
5558e5f728 Changing the host verbosity flag to -d|--diagnostics from -v|--verbosity so that it is not confused with the verbs verbosity flag. 2016-12-16 12:58:34 -08:00
Justin Goshi
ae1e183e41 Complete the refactor and test improvements 2016-12-16 10:23:26 -08:00
Justin Goshi
82f5278d8a Merge branch 'rel/1.0.0' into dev/jgoshi/removeProj 2016-12-16 08:44:38 -08:00
Justin Goshi
806d5a2589 Implement dotnet list projects (#5027)
* Implement dotnet list projects

* Address PR comments

* Fix build breaks
2016-12-16 06:41:47 -10:00
Arun Mahapatra
f3a74f1162 Return non-zero exit code for test failure in multitargeted test project.
Treat the errors from vstest task as errors (instead of warnings) before continuing further.
Add asserts for exit code in tests for dotnet-test and dotnet-vstest.
2016-12-16 15:39:52 +05:30
Justin Goshi
023a899db0 WIP Refactor and improve tests 2016-12-16 01:04:09 -08:00
Justin Goshi
20f2242947 Adding dotnet remove project tests 2016-12-15 15:48:04 -08:00
Livar Cunha
e710958b79 Adding a Exclude @(EmbeddedResource) during migration so that we don't get duplicate resources when building migrated apps. 2016-12-15 11:17:20 -08:00
Justin Goshi
441277ccfa Implement dotnet add project (#5022)
* Implement dotnet add project

* Addressed PR comments
2016-12-14 13:53:11 -10:00
Livar Cunha
56dd76bdb0 Adding Update under Content for BuildOptions as well, but limiting this change only to Web Apps at the moment, because regular SDK does not have Content Include=**/* in place yet. 2016-12-13 16:45:40 -08:00
Livar Cunha
a22f4be938 Adding a UpdateContextTransform that generates items with the Update attribute set instead of Include. Also, removed the Exists condition for published content, because now that we are using Update, that check is not needed. I left the option to set a condition on the metadata though. 2016-12-13 16:45:39 -08:00
Livar Cunha
84682562bf Adding a condition to Content CopyToPublishDirectory to validate that the file exists before trying to copy it to output, to keep the same functionality as it existed in PJ. In MSBuild world, without this condition, CopyToPublishDirectory will fail. 2016-12-13 16:45:39 -08:00
Justin Goshi
76722fd403 Improve the help text (#5002)
* WIP Improve help text

* Improve help text

* Address PR comments

* Address PR comments

* Address PR comments
2016-12-13 14:31:35 -10:00
Piotr Puszkiewicz
2fbafe6f3f Remove StreamForwarder from CLI tests (#4936)
* WiP

* Replace StreamForwarder with OutputDataReceived

* Add build logging around test execution

* add newlines

* Add handling for the null terminator while maintaining empty lines

* Extra Diag

* Verbose logging for VS Test Console

* Fix asset file locking tests

* Add testcommand timeout + improve dotnet-new tests

* WiP

* Welcome, JoSequ!

* Fix failing tests

* Clean out diagnostics writelines

* self-PR1
2016-12-13 14:15:35 -08:00
Justin Goshi
2b7e9b6524 Clean up sln reader/writer (#5005) 2016-12-13 06:45:00 -10:00
Zlatko Knezevic
d335b5de40 Changing dotnet-test options (#4987)
In Preview 3, the `dotnet test` options were not aligned with the CLI's
adopted format. This PR changes the options to be aligned. Where
possible/applicable, I have shortened the long options to a meaningful
mnemonic short version.

Fixes #4960
2016-12-12 23:29:29 -08:00
Livar
1a49787a1f Merge pull request #4993 from livarcocc/cyclic_dependency_test
Adding a test that validates CLI templates don't depend on CLI packages.
2016-12-12 15:48:41 -08:00
Livar Cunha
e1965327e0 Adding a test that restores all c# templates and checks that none of them depend on a package produced by the CLI. I had to write this as a single test for all templates because it cuts the test time in about half to restore all the packages at once to the same folder than to clean and restore again everytime per template. 2016-12-09 16:11:57 -08:00
Livar
bd590f51e6 Emitting PackageId whenever we emit AssemblyName. We need to do this to preserve the behavior from PJ where the package id matched the containing PJ folder name. In MSBuild, PackageId will match AssemblyName, unless it is explicitly specified. (#4990) 2016-12-09 16:10:16 -08:00
Krzysztof Wicher
8eaec8715b Merge pull request #4972 from krwq/p2p-compat-check
add compat checks to dotnet add
2016-12-09 15:32:15 -08:00
Krzysztof Wicher
524fe3cb6b apply review feedback 2016-12-09 12:11:11 -08:00
Piotr Puszkiewicz
70c8ecbf16 Merge branch 'rel/1.0.0' into migrate_pj_without_frameworks 2016-12-09 00:30:36 -08:00
Livar
1fd99f1588 Merge rel/1.0.0-preview4 back into rel/1.0.0 (#4974)
* Updating the preview4 channel to rel-1.0.0-preview4

* Add more xlf files for new strings

* bundle fsharp sdk, only Sdk directory is required

* align f# console proj

* align f# lib template

* align f# mstest template

* align f# xunit template

* align f# web template

* fix mstest package version, aligned to c#

* remove unused directories from bundled sdks

* Adding a SdkNugetVersion property when invoking dotnet pack on test packages so that test packages can reference exact packages. We need that because of https://github.com/NuGet/Home/issues/4063. Without it, pack creates the nuspec with a version like 1.0.0-version-, instead of 1.0.0-version-<version_used_in_build>, which leads to problems when restoring the tool. Like, it ends up restoring to the closest version of the package (oldest), instead of the latest.

* Update web template for Web SDK 154 (#4948)

* Update WebSDK version

* Update web template to get rid of globs

https://github.com/aspnet/Templates/pull/735

* MSBuild to 15.1.458 (#4950)

* Adding MigrateWebSdkRule to the DefaultMigrationRuleSet (#4963)

* Adding MigrateWebSdkRule to the DefaultMigrationRuleSet and adding a E2E test to cover it.

* Do not migrate compile and EmbeddedResources for web application, because those are included in the Web Sdk already.

* Addressing code review comments
2016-12-09 00:30:02 -08:00
Livar Cunha
9bddb5bac7 Addressing code review comments. 2016-12-08 20:06:55 -08:00
Livar Cunha
bb1bceb8bb When we had a project.json without frameworks, we were failing to show the appropriate error message because when we were generating the error message itself we tried to access the project context (which requires a framework in the PJ). This fix makes the ProjectContext optional to add the migration error. 2016-12-08 19:53:35 -08:00
Krzysztof Wicher
9a8d158e09 add test coverage 2016-12-08 16:23:21 -08:00