package org.jerrymouse.cc.site.view.redirecter;

import static org.junit.Assert.*;

import org.jerrymouse.cc.site.bean.Resource;
import org.jerrymouse.cc.site.bean.Storage;
import org.jerrymouse.cc.site.database.UserDao;
import org.jerrymouse.cc.site.test.BaseTest;
import org.jerrymouse.cc.site.view.redirecter.GoogleDocRedirect;
import org.jerrymouse.cc.site.view.redirecter.ZohoRedirecter;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;

public class ZohoRedirecterTest extends BaseTest {
	Resource resource;

	@Autowired
	UserDao userDao;

	@Override
	protected void onSetUp() throws Exception {
		Storage storage = userDao.getUserByName("yankai").getStorage();
		resource = storage.getResourceByName("1");
		super.onSetUp();
	}

	@Test
	public void testview() {
		ZohoRedirecter zohoViewer = new ZohoRedirecter();
		zohoViewer.view(resource);
	}
}
