Commit Graph

19 Commits

Author SHA1 Message Date
YishaiGalatzer 80ef37ab0a Add unit tests to controller properties 2014-10-09 18:18:03 -07:00
jacalvar a2023d35ee [Fixes #429] FileResult
1) Implemented FilePathResult to efficiently return files from disk.
2) Implemented FileStreamResult to return content from a stream.
3) Implemented FileContentResult to return content from a byte array.
2014-10-02 12:50:24 -07:00
Pranav K 38e82c0aa5 Updating Microsoft.AspNet.Mvc.Core.Test to work on Mono 2014-10-01 10:05:36 -07:00
David Fowler 34add2249e Updated to use the new target framework in project.json 2014-09-04 02:02:40 -07:00
jacalvar b6fb7ac7df Take advantage of nameof to improve our usage of MemberData across the code base.
Substituted all instances of [MemberData("PropertyName")] for [MemberData(nameof(PropertyName))]
This change enables us to take advantage of IDE features like Navigate to source,
find all references, etc. When using Visual Studio.
2014-09-02 13:53:03 -07:00
Pranav K d604c18368 Moving IModelValidatorProvider to Options
Fixes #879
2014-08-26 11:53:32 -07:00
harshgMSFT 6f0fa67170 Enabling basic input formatter selection.
Conflicts:
	Mvc.sln
	src/Microsoft.AspNet.Mvc.Core/Formatters/TempInputFormatterProvider.cs
	src/Microsoft.AspNet.Mvc.Core/Microsoft.AspNet.Mvc.Core.kproj
	src/Microsoft.AspNet.Mvc.Core/ReflectedActionInvoker.cs
	src/Microsoft.AspNet.Mvc.Core/ReflectedActionInvokerProvider.cs
	src/Microsoft.AspNet.Mvc/MvcServices.cs
	test/Microsoft.AspNet.Mvc.Core.Test/Microsoft.AspNet.Mvc.Core.Test.kproj
	test/Microsoft.AspNet.Mvc.Core.Test/ReflectedActionInvokerTest.cs

Conflicts:
	src/Microsoft.AspNet.Mvc.Core/Formatters/TempInputFormatterProvider.cs
2014-08-19 12:46:52 -07:00
harshgMSFT bb452f19a7 JsonResult to use ObjectResult for content negotiation to pick default json formatter. 2014-08-15 15:56:24 -07:00
Javier Calvarro Nelson b0d52f73fd [Issue #527] Revive common ActionResults - Part 1.
1. Added HttpNotFound() to Controller.
2. Updated HttpStatusCodeResult to expose the StatusCode as a property.
3. Added unit tests for HttpNotFound() and for HttpStatusCodeResult.
4. Updated the MvcSample to add an action that uses HttpNotFound().
5. Brought back HttpNotFoundResult and added unit tests for it.
2014-07-25 13:04:59 -07:00
Pranav K 24f74222f5 Introducing Controller.TryUpdateModel
This changeset reintroduces some of the overloads for
Controller.TryUpdateModel.

Fixes #415
2014-07-25 10:08:44 -07:00
Tian Pan 4c9f19aafc Update controller methods to be all virtual
Fix #596
2014-06-20 15:40:02 -07:00
Ryan Nowak 1bae3bcaa2 Issue #592 - ActionResult is not being executed by ResultFilterAttribute
The issue here is actually different than described in the bug.
ResultFilter should only short circuit when .Cancel is set to true. This
is consistent with legacy MVC.

Added tests for all of this stuff. There's already good test coverage for
the invoker, what was missing was coverage for the attributes and for the
methods on Controller. ExceptionFilterAttribute and
AuthorizationFilterAttribute don't have short circuiting logic inside of
them, so they are already covered by tests for the invoker.
2014-06-16 12:42:59 -07:00
Tian Pan e95585dfbd Remove ActionResultHelper
Fix #597
2014-06-11 11:17:45 -07:00
Tian Pan 60443101d5 Enable request to reach base controller class's action
Fix #378
2014-06-11 10:57:19 -07:00
Andrew Peters f13865dedc Updating copyright headers 2014-05-08 23:01:20 -07:00
anpete 8208cd6b2f Update file headers 2014-05-01 17:42:33 -07:00
Sornakumar ecd8ddeae4 WebFX 156: Adding support for RedirectToAction and RedirectToRoute 2014-04-15 10:45:57 -07:00
sornaks 7c8dd45b8b WebFX 156 - Adding support for Redirect and RedirectPermanent 2014-04-08 10:49:56 -07:00
dougbu 8ed5b7b079 Fix WebFx-169 and #118
- move `DynamicObject` derivation up to new `DynamicViewData` class, fixing [WebFx-169](http://projectk-tc:8080/browse/WEBFX-169)
- avoid direct `_data` lookup in previous `TryGetMember()`, fixing [#118](https://github.com/aspnet/WebFx/issues/118)
- rename ViewData -> ViewDataDictionary

Also
- flesh out `IDictionary<string, object>` implementation in `ViewData`
- provide `ViewData` copy constructor that allows TModel to change
- remove `TryGetIndex()` and `TrySetIndex()` implementations; use `ViewData[]` instead
- restore `ViewContext.ViewBag` from legacy MVC
2014-03-26 11:42:52 -07:00