Package com.google.refine.model

Examples of com.google.refine.model.Project


        Assert.assertEquals(columnNames.size(), 4);
    }

    @Test
    public void setupColumns(){
        Project project = new Project();
        List<String> columnNames = new ArrayList<String>();
        columnNames.add("col1");
        columnNames.add("col2");
        columnNames.add("");
        ImporterUtilities.setupColumns(project, columnNames);
View Full Code Here


    XmlImportUtilitiesStub SUT;

    @BeforeMethod
    public void SetUp(){
        SUT = new XmlImportUtilitiesStub();
        project = new Project();
        columnGroup = new ImportColumnGroup();
        record = new ImportRecord();
    }
View Full Code Here

    public void setUp(){
        //FIXME - should we try and use mock(Project.class); - seems unnecessary complexity

        servlet = new RefineServletStub();
        ImportingManager.initialize(servlet);
        project = new Project();
        metadata = new ProjectMetadata();
        job = ImportingManager.createJob();
       
        options = Mockito.mock(JSONObject.class);
    }
View Full Code Here

    public void SetUp(){
        SUT = new XlsExporter(false);
        stream = new ByteArrayOutputStream();
        ProjectManager.singleton = new ProjectManagerStub();
        projectMetadata = new ProjectMetadata();
        project = new Project();
        projectMetadata.setName(TEST_PROJECT_NAME);
        ProjectManager.singleton.registerProject(project, projectMetadata);
        engine = new Engine(project);
        options = mock(Properties.class);
    }
View Full Code Here

    public void SetUp(){
        SUT = new TemplatingExporter();
        writer = new StringWriter();
        ProjectManager.singleton = new ProjectManagerStub();
        projectMetadata = new ProjectMetadata();
        project = new Project();
        projectMetadata.setName(TEST_PROJECT_NAME);
        ProjectManager.singleton.registerProject(project, projectMetadata);
        engine = new Engine(project);
        options = mock(Properties.class);
    }
View Full Code Here

    @BeforeMethod
    public void SetUp(){
        SUT = new CsvExporter('\t');//new TsvExporter();
        writer = new StringWriter();
        project = new Project();
        engine = new Engine(project);
        options = mock(Properties.class);
    }
View Full Code Here

    public void canSaveAllModified(){
        whenGetSaveTimes(project, metadata); //5 minute difference
        registerProject(project, metadata);

        //add a second project to the cache
        Project project2 = spy(new ProjectStub(2));
        ProjectMetadata metadata2 = mock(ProjectMetadata.class);
        whenGetSaveTimes(project2, metadata2, 10); //not modified since the last save but within 30 seconds flush limit
        registerProject(project2, metadata2);

        //check that the two projects are not the same
View Full Code Here

    @BeforeMethod
    public void SetUp(){
        projectManager = mock(ProjectManager.class);
        ProjectManager.singleton = projectManager;
        proj = new Project();
        SUT = new History(proj);
    }
View Full Code Here

    @Test
    public void canAddEntry(){
        //local dependencies
        HistoryEntry entry = mock(HistoryEntry.class);
        Project project = mock(Project.class);
        ProjectMetadata projectMetadata = mock(ProjectMetadata.class);

        when(projectManager.getProject(Mockito.anyLong())).thenReturn(project);
        when(projectManager.getProjectMetadata(Mockito.anyLong())).thenReturn(projectMetadata);
View Full Code Here

    }


    @BeforeMethod
    public void SetUp() {
        project = new Project();
        bindings = ExpressionUtils.createBindings(project);
    }
View Full Code Here

TOP

Related Classes of com.google.refine.model.Project

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.