Пример #1
0
        public void TestStringOfJSONCtr()
        {
            String id = "http://adlnet.gov/expapi/verbs/experienced";
            String json = "{\"id\":\"" + id + "\"}";
            StringOfJSON strOfJson = new StringOfJSON(json);

            Verb obj = new Verb(strOfJson);
            Assert.IsInstanceOf<Verb>(obj);
            Assert.That(obj.ToJSON(), Is.EqualTo(json));
        }
Пример #2
0
        public void TestStringOfJSONCtr()
        {
            var json = "{\"success\": true, \"completion\": true, \"response\": \"Yes\"}";
            var strOfJson = new StringOfJSON(json);

            var obj = new Result(strOfJson);
            Assert.IsInstanceOf<Result>(obj);
            Assert.That(obj.success, Is.EqualTo(true));
            Assert.That(obj.completion, Is.EqualTo(true));
            Assert.That(obj.response, Is.EqualTo("Yes"));
        }
Пример #3
0
        public void TestStringOfJSONCtr()
        {
            var mbox = "mailto:[email protected]";

            var json = "{\"mbox\":\"" + mbox + "\"}";
            var strOfJson = new StringOfJSON(json);

            var obj = new Agent(strOfJson);
            Assert.IsInstanceOf<Agent>(obj);
            Assert.That(obj.mbox, Is.EqualTo(mbox));
        }
Пример #4
0
 public Activity(StringOfJSON json) : this(json.toJObject()) { }
Пример #5
0
 public ContextActivities(StringOfJSON json): this(json.toJObject()) {}
Пример #6
0
 public Statement(StringOfJSON json) : this(json.toJObject()) { }
Пример #7
0
 public Result(StringOfJSON json): this(json.toJObject()) {}
Пример #8
0
 public About(StringOfJSON json) : this(json.toJObject()) {}
Пример #9
0
 public Score(StringOfJSON json): this(json.toJObject()) {}
Пример #10
0
 public LanguageMap(StringOfJSON json) : this(json.toJObject()) { }
Пример #11
0
 public ActivityDefinition(StringOfJSON json): this(json.toJObject()) {}
Пример #12
0
 public Context(StringOfJSON json): this(json.toJObject()) {}
Пример #13
0
 public AgentAccount(StringOfJSON json) : this(json.toJObject()) { }
Пример #14
0
 public Group(StringOfJSON json) : this(json.toJObject()) { }
Пример #15
0
 public Verb(StringOfJSON json): this(json.toJObject()) {}