def test_online_with_wrong_kwargs(neptune_mock):
    """Tests combinations of kwargs together with `run` kwarg which makes some of other parameters unavailable in
    init."""
    run = neptune_mock.init_run()

    with pytest.raises(ValueError):
        NeptuneLogger(run="some string")

    with pytest.raises(ValueError):
        NeptuneLogger(run=run, project="redundant project")

    with pytest.raises(ValueError):
        NeptuneLogger(run=run, api_key="redundant api key")

    with pytest.raises(ValueError):
        NeptuneLogger(run=run, name="redundant api name")

    with pytest.raises(ValueError):
        NeptuneLogger(run=run, foo="random **kwarg")

    # this should work
    NeptuneLogger(run=run)
    NeptuneLogger(project="foo")
    NeptuneLogger(foo="bar")
Tests combinations of kwargs together with `run` kwarg which makes some of other parameters unavailable in
    init.
tests/tests_pytorch/loggers/test_neptune.py