예제 #1
0
def test_expand_rule():
    from rospkg.distro import expand_rule

    assert "foo" == expand_rule("$STACK_NAME", "foo", "version", "release")
    assert "version" == expand_rule("$STACK_VERSION", "foo", "version", "release")
    assert "release" == expand_rule("$RELEASE_NAME", "foo", "version", "release")
    assert "foo-version-release" == expand_rule("$STACK_NAME-$STACK_VERSION-$RELEASE_NAME", "foo", "version", "release")
예제 #2
0
def test_expand_rule():
    from rospkg.distro import expand_rule
    assert 'foo' == expand_rule('$STACK_NAME', 'foo', 'version', 'release')
    assert 'version' == expand_rule('$STACK_VERSION', 'foo', 'version',
                                    'release')
    assert 'release' == expand_rule('$RELEASE_NAME', 'foo', 'version',
                                    'release')
    assert 'foo-version-release' == expand_rule(
        '$STACK_NAME-$STACK_VERSION-$RELEASE_NAME', 'foo', 'version',
        'release')
예제 #3
0
def test_expand_rule():
    from rospkg.distro import expand_rule
    assert 'foo' == expand_rule('$STACK_NAME', 'foo', 'version', 'release')
    assert 'version' == expand_rule('$STACK_VERSION', 'foo', 'version', 'release')
    assert 'release' == expand_rule('$RELEASE_NAME', 'foo', 'version', 'release')
    assert 'foo-version-release' == expand_rule('$STACK_NAME-$STACK_VERSION-$RELEASE_NAME', 'foo', 'version', 'release')