Package org.joda.time

Examples of org.joda.time.Duration


 
  @Before
  public void before() {
    date = new LocalDate().minusDays(1);
    workspace = new WorkspaceStorage(new Path(""), new Path(""));
    duration = new Duration(10);
    partId = "abc";
  }
View Full Code Here


  @Before
  public void setup() {
    root = ResourcesPlugin.getWorkspace().getRoot();
    fileHasParentFolder = root.getFile(new Path("/project/folder/file.txt"));
    duration = new Duration(100);
    date = new LocalDate().minusDays(1);
    ws = new WorkspaceStorage(new Path(".a"), new Path("/a"));

    data = mock(IFileData.class);
    given(data.get(IFileData.DATE)).willReturn(date);
View Full Code Here

  @Override
  public void shouldCorrectlyBuildMultiplePaths() {
    WorkspaceStorage ws2 = new WorkspaceStorage(new Path(".b"), null);
    LocalDate date2 = date.minusDays(2);
    Duration duration2 = duration.withMillis(10000);
    IFile fileHasNoParentFolder = root.getFile(new Path("/project/file.txt"));

    ICategory[] categories = {
        Category.PROJECT,
        Category.FOLDER,
View Full Code Here

  IPartData data;

  @Before
  public void setup() {
    duration = new Duration(100);
    view = PlatformUI.getWorkbench().getViewRegistry().getViews()[0];
    date = new LocalDate().minusDays(1);
    ws = new WorkspaceStorage(new Path(".a"), new Path("/a"));

    data = mock(IPartData.class);
View Full Code Here

  @Override
  public void shouldCorrectlyBuildMultiplePaths() {
    WorkspaceStorage ws2 = new WorkspaceStorage(new Path(".b"), null);
    LocalDate date2 = date.minusDays(2);
    Duration duration2 = duration.withMillis(10000);
    IEditorDescriptor editor = PlatformUI.getWorkbench().getEditorRegistry()
        .getDefaultEditor("1.txt");

    ICategory[] categories = {Category.WORKSPACE, Category.WORKBENCH_TOOL};
    List<TreePath> expected = asList(
View Full Code Here

  ISessionData data;

  @Before
  public void setup() {
    date = new LocalDate().minusDays(1);
    duration = new Duration(System.currentTimeMillis());
    ws = new WorkspaceStorage(new Path(".a"), new Path("/a"));

    data = mock(ISessionData.class);
    given(data.get(ISessionData.DATE)).willReturn(date);
    given(data.get(ISessionData.DURATION)).willReturn(duration);
View Full Code Here

  @Override
  public void shouldCorrectlyBuildMultiplePaths() {
    WorkspaceStorage ws2 = new WorkspaceStorage(new Path(".b"), null);
    LocalDate date2 = date.minusDays(2);
    Duration duration2 = duration.withMillis(10000);

    ICategory[] categories = {Category.WORKSPACE, Category.DATE};
    List<TreePath> expected = asList(
        newPath(ws, date, duration),
        newPath(ws2, date2, duration2));
View Full Code Here

  IPerspectiveData data;

  @Before
  public void setup() {
    duration = new Duration(100);
    perspective = PlatformUI.getWorkbench().getPerspectiveRegistry()
        .getPerspectives()[0];
    date = new LocalDate().minusDays(1);
    ws = new WorkspaceStorage(new Path(".a"), new Path("/a"));
View Full Code Here

  @Override
  public void shouldCorrectlyBuildMultiplePaths() {
    WorkspaceStorage ws2 = new WorkspaceStorage(new Path(".b"), null);
    LocalDate date2 = date.minusDays(2);
    Duration duration2 = duration.withMillis(10000);
    IPerspectiveDescriptor p2 = PlatformUI.getWorkbench()
        .getPerspectiveRegistry().getPerspectives()[1];

    ICategory[] categories = {Category.WORKSPACE, Category.PERSPECTIVE};
    List<TreePath> expected = asList(
View Full Code Here

    type = manager.getLaunchConfigurationTypes()[0];
    mode = manager.getLaunchModes()[0];

    count = 10;
    date = new LocalDate().minusDays(1);
    duration = new Duration(101);
    launch = new LaunchName("hello", type.getIdentifier());
    ws = new WorkspaceStorage(new Path("/a"), new Path(".a"));
    fileHasParent = root.getFile(new Path("/project/folder/folder1/file.txt"));
    fileHasNoParent = root.getFile(new Path("/project/file.txt"));
    configDes = new LaunchConfigurationDescriptor(
View Full Code Here

TOP

Related Classes of org.joda.time.Duration

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.