Beispiel #1
0
        public void GetObjectCollectionTest()
        {
            var projectIds = new List <int>()
            {
                _configData.ProjectId
            };
            var someDataObject = _serviceObject.GetObjectCollection("projects/", projectIds);

            Assert.IsNotNull(someDataObject);
            Assert.AreEqual(someDataObject.ToList()[0].Data.Id, _configData.ProjectId);
            Assert.AreEqual(someDataObject.ToList().Count, 1);
        }
Beispiel #2
0
        public void GetObjectCollection_InvalidCredential()
        {
            var projectIds = new List <int> {
                _configData.ProjectId
            };

            _serviceObject = new GcDataRepository <GcProject>("123", _configData.Email);
            var someDataObject = _serviceObject.GetObjectCollection("projects/", projectIds);

            Assert.IsNotNull(someDataObject);
            Assert.AreEqual(someDataObject.ToList()[0].Data, null);
            Assert.AreEqual(someDataObject.ToList().Count, 1);
        }
Beispiel #3
0
 public ICollection <GcDataObject <GcAccount> > GetAccountsByIds(IEnumerable <int> accountIds)
 {
     return(_accountClient.GetObjectCollection("accounts/", accountIds.ToList()));
 }
Beispiel #4
0
 public ICollection <GcDataObject <GcTemplate> > GetTemplatesByIds(List <int> templateIds)
 {
     return(_templateClient.GetObjectCollection("templates/", templateIds));
 }
Beispiel #5
0
 public ICollection <GcDataObject <GcItem> > GetItemsByIds(List <int> itemIds)
 {
     return(_itemClient.GetObjectCollection("items/", itemIds));
 }
Beispiel #6
0
        public ICollection <GcDataObject <GcStatus> > GetStatusesByIds(int projectId, IEnumerable <int> statusIds)
        {
            var urlPath = $"projects/{projectId}/statuses/";

            return(_statusClient.GetObjectCollection(urlPath, statusIds.ToList()));
        }
Beispiel #7
0
 public ICollection <GcDataObject <GcProject> > GetProjectsByIds(List <int> projectIds)
 {
     return(_projectClient.GetObjectCollection("projects/", projectIds));
 }