Package org.jmock

Examples of org.jmock.Mock.verify()


        expectVisitClass( mock, "a.b.c", "class a.b.c" );
        expectVisitClass( mock, "x.y.z", "class x.y.z" );

        ClassFileVisitorUtils.accept( file.toURI().toURL(), (ClassFileVisitor) mock.proxy() );

        mock.verify();
    }

    public void testAcceptJarWithNonClassEntry()
        throws IOException
    {
View Full Code Here


        Mock mock = mock( ClassFileVisitor.class );

        ClassFileVisitorUtils.accept( file.toURI().toURL(), (ClassFileVisitor) mock.proxy() );

        mock.verify();
    }

    public void testAcceptDir()
        throws IOException
    {
View Full Code Here

        ClassFileVisitorUtils.accept( dir.toURI().toURL(), (ClassFileVisitor) mock.proxy() );

        FileUtils.deleteDirectory( dir );

        mock.verify();
    }

    public void testAcceptDirWithNonClassFile()
        throws IOException
    {
View Full Code Here

        ClassFileVisitorUtils.accept( dir.toURI().toURL(), (ClassFileVisitor) mock.proxy() );

        FileUtils.deleteDirectory( dir );

        mock.verify();
    }

    public void testAcceptWithFile()
        throws IOException
    {
View Full Code Here

    }
    catch (ValidatorException ve)
    {
      // suppress it - this is as expected
    }
    mock.verify();
  }

  public void testWrongType()
  {
    // since the pattern has not been set it will be null
View Full Code Here

    }
    catch (ValidatorException ve)
    {
      // suppress it - this is as expected
    }
    mock.verify();
  }

  public void testExactFailure()
  {
    // some very basic sanity test
View Full Code Here

    catch (ValidatorException ve)
    {
      // if exception then fine.
    }

    mock.verify();
  }

  public void testSanitySuccess()
  {
    //some very basic sanity test
View Full Code Here

    }
    catch (ValidatorException ve)
    {
      // suppress it - this is as expected
    }
    mock.verify();
  }

  public void testWrongType()
  {
    // since the pattern has not been set it will be null
View Full Code Here

    }
    catch (ValidatorException ve)
    {
      // suppress it - this is as expected
    }
    mock.verify();
  }

  public void testExactFailure()
  {
    // some very basic sanity test
View Full Code Here

    catch (ValidatorException ve)
    {
      // if exception then fine.
    }

    mock.verify();
  }

  public void testSanitySuccess()
  {
    //some very basic sanity test
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.