public void GetDatalistTitle_IsCaseInsensitive()
        {
            String expected = RadyaLabs.Resources.Datalist.Titles.Role;
            String actual   = ResourceProvider.GetDatalistTitle("role");

            Assert.Equal(expected, actual);
        }
Exemplo n.º 2
0
        public MvcDatalist(UrlHelper url)
        {
            String view = typeof(TView).Name.Replace("View", "");

            Url   = url.Action(view, Prefix, new { area = "" });
            Title = ResourceProvider.GetDatalistTitle(view);
        }
        public void GetDatalistTitle_GetsTitle()
        {
            String expected = MvcTemplate.Resources.Datalist.Titles.Role;
            String actual   = ResourceProvider.GetDatalistTitle <Role>();

            Assert.Equal(expected, actual);
        }
Exemplo n.º 4
0
        public void GetDatalistTitle_IsCaseInsensitive()
        {
            String expected = VumbaSoft.Masterdetails.Resources.Datalist.Titles.Role;
            String actual   = ResourceProvider.GetDatalistTitle("role");

            Assert.Equal(expected, actual);
        }
Exemplo n.º 5
0
        public BaseDatalist()
        {
            DialogTitle = ResourceProvider.GetDatalistTitle <TModel>();
            UrlHelper urlHelper = new UrlHelper(HttpContext.Current.Request.RequestContext);

            DatalistUrl = urlHelper.Action(typeof(TModel).Name, Prefix, new { area = "" });
        }
Exemplo n.º 6
0
        public void BaseDatalist_SetsDialogTitle()
        {
            String expected = ResourceProvider.GetDatalistTitle <Role>();
            String actual   = datalist.DialogTitle;

            Assert.AreEqual(expected, actual);
        }
Exemplo n.º 7
0
        public BaseDatalist()
        {
            HttpRequest request   = HttpContext.Current.Request;
            UrlHelper   urlHelper = new UrlHelper(request.RequestContext);

            DialogTitle = ResourceProvider.GetDatalistTitle <TModel>();
            DatalistUrl = urlHelper.Action(typeof(TModel).Name, Prefix, new { area = String.Empty }, request.Url.Scheme);
        }
Exemplo n.º 8
0
        public void Datalist_SetsDialogTitle()
        {
            datalist = new MvcDatalist <Role, RoleView>(url);

            String expected = ResourceProvider.GetDatalistTitle(typeof(RoleView).Name.Replace("View", ""));
            String actual   = datalist.Title;

            Assert.Equal(expected, actual);
        }
Exemplo n.º 9
0
        public void BaseDatalist_SetsDialogTitle()
        {
            datalist = new BaseDatalistProxy <Role, RoleView>(urlHelper);

            String expected = ResourceProvider.GetDatalistTitle <Role>();
            String actual   = datalist.DialogTitle;

            Assert.Equal(expected, actual);
        }
 public void GetDatalistTitle_NullDatalist_ReturnsNull()
 {
     Assert.Null(ResourceProvider.GetDatalistTitle(null));
 }
 public void GetDatalistTitle_NotFound_ReturnsNull()
 {
     Assert.Null(ResourceProvider.GetDatalistTitle("Test"));
 }
 public void GetDatalistTitle_OnTypeNotFoundReturnsNull()
 {
     Assert.Null(ResourceProvider.GetDatalistTitle <Object>());
 }
Exemplo n.º 13
0
 public BaseDatalist(UrlHelper url)
 {
     DialogTitle = ResourceProvider.GetDatalistTitle <TModel>();
     DatalistUrl = url.Action(typeof(TModel).Name, Prefix, new { area = "" });
 }