def METHOD_NAME(variant_scalar_rgb):
    assert fs.path("dir" + sep + "file.ext").extension() == ".ext"
    assert fs.path("dir" + sep).extension() == ""
    assert (path_here / fs.path(".hidden")).extension() == ".hidden"
    assert empty_path.extension() == ""
    assert fs.path(".").extension() == ""
    assert fs.path("..").extension() == ""
    assert fs.path("foo" + sep + ".").extension() == ""
    assert fs.path("foo" + sep + "..").extension() == ""
    # Replace extension
    assert empty_path.replace_extension(".ext") == empty_path
    assert fs.path(".").replace_extension(".ext") == fs.path(".")
    assert fs.path("..").replace_extension(".ext") == fs.path("..")
    assert fs.path("foo.bar").replace_extension(".ext") == fs.path("foo.ext")
    assert fs.path("foo.bar").replace_extension(fs.path(".ext")) == \
        fs.path("foo.ext")
    assert fs.path("foo").replace_extension(".ext") == fs.path("foo.ext")
    assert fs.path("foo.bar").replace_extension("none") == fs.path("foo.none")
    assert fs.path(sep + "foo" + sep + "bar.foo").replace_extension(".jpg") == \
        fs.path(sep + "foo" + sep + "bar.jpg")