コード例 #1
0
        public void MediaProvider_VineTest()
        {
            Uri uri = new Uri("https://mtc.cdn.vine.co/r/videos_h264high/28D3E01F201216824363924803584_SW_WEBM_1433087743394462be3b271.mp4");

            PrivateType pt = new PrivateType(typeof(TweetHelper));

            IMediaProvider mediaProvider = (IMediaProvider)pt.InvokeStatic("GetMediaProvider", new object[] { uri });

            Assert.AreEqual(typeof(Vine), mediaProvider.GetType());
        }
コード例 #2
0
        public void MediaProvider_TwippleTest()
        {
            Uri uri = new Uri("http://p.twipple.jp/2d1sn");

            PrivateType pt = new PrivateType(typeof(TweetHelper));

            IMediaProvider mediaProvider = (IMediaProvider)pt.InvokeStatic("GetMediaProvider", new object[] { uri });

            Assert.AreEqual(typeof(Twipple), mediaProvider.GetType());
        }