def test_skip0007(): config = Config() with pytest.raises(ValueError) as e: config.should_skip("wobble") assert e.value.message == "bad benchmark key: wobble"
def test_skip0007(): config = Config() with pytest.raises(ValueError) as e: config.should_skip("wobble") assert e.value.args[0] == "bad benchmark key: wobble"
def test_skip0006(): config = Config() config.SKIP = ["*:*:*"] assert config.should_skip("mybench:CPython:default-python") assert config.should_skip("myotherbench:CPython:default-python") assert config.should_skip("mybench:PyPy:default-python") assert config.should_skip("mybench:CPython:special-python")
def test_skip0001(): path = os.path.join(TEST_DIR, "skips.krun") config = Config(path) expected = ["*:PyPy:*", "*:CPython:*", "*:Hotspot:*", "*:Graal:*", "*:LuaJIT:*", "*:HHVM:*", "*:TruffleRuby:*", "*:V8:*", ] for triplet in expected: assert config.should_skip(triplet) assert config.should_skip("nbody:HHVM:default-php") assert not config.should_skip("nbody:MYVM:default-php")
def test_skip0001(): path = os.path.join(TEST_DIR, "skips.krun") config = Config(path) expected = ["*:PyPy:*", "*:CPython:*", "*:Hotspot:*", "*:Graal:*", "*:LuaJIT:*", "*:HHVM:*", "*:JRubyTruffle:*", "*:V8:*", ] for triplet in expected: assert config.should_skip(triplet) assert config.should_skip("nbody:HHVM:default-php") assert not config.should_skip("nbody:MYVM:default-php")
def test_skip0010(): config = Config() config.SKIP = ["*:SomeVM:*", "fasta:TruffleRuby:default-ruby", "bench:*:*", "bench:vm:skipvariant", "*:*:skipvariant", "*:*:*", # everything should be skipped due to this ] import uuid def rand_str(): return uuid.uuid4().hex for i in xrange(25): key = "%s:%s:%s" % tuple([rand_str() for x in xrange(3)]) assert config.should_skip(key)
def test_skip0010(): config = Config() config.SKIP = ["*:SomeVM:*", "fasta:JRubyTruffle:default-ruby", "bench:*:*", "bench:vm:skipvariant", "*:*:skipvariant", "*:*:*", # everything should be skipped due to this ] import uuid def rand_str(): return uuid.uuid4().hex for i in xrange(25): key = "%s:%s:%s" % tuple([rand_str() for x in xrange(3)]) assert config.should_skip(key)
def test_skip0009(): config = Config() config.SKIP = ["*:SomeVM:*", "fasta:TruffleRuby:default-ruby", "bench:*:*", "bench:vm:skipvariant", "*:*:skipvariant", ] assert config.should_skip("fasta:TruffleRuby:default-ruby") assert not config.should_skip("fasta:TruffleRuby:default-ruby2") assert config.should_skip("bench:lala:hihi") assert config.should_skip("bench:lala:hihi2") assert not config.should_skip("bench1:lala:hihi") assert config.should_skip("bench1:lala:skipvariant") assert config.should_skip("bench1:lala2:skipvariant")
def test_skip0009(): config = Config() config.SKIP = ["*:SomeVM:*", "fasta:JRubyTruffle:default-ruby", "bench:*:*", "bench:vm:skipvariant", "*:*:skipvariant", ] assert config.should_skip("fasta:JRubyTruffle:default-ruby") assert not config.should_skip("fasta:JRubyTruffle:default-ruby2") assert config.should_skip("bench:lala:hihi") assert config.should_skip("bench:lala:hihi2") assert not config.should_skip("bench1:lala:hihi") assert config.should_skip("bench1:lala:skipvariant") assert config.should_skip("bench1:lala2:skipvariant")
def test_skip0008(): config = Config() config.SKIP = ["*:SomeVM:*", "fasta:TruffleRuby:default-ruby"] assert config.should_skip("fasta:TruffleRuby:default-ruby")