You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
322 B

import pmxbot
import wolframalpha.pmxbot
def test_pmxbot_command(monkeypatch, API_key):
config = {'Wolfram|Alpha API key': API_key}
monkeypatch.setattr(pmxbot, 'config', config, raising=False)
query = "1kg in lbs"
res = wolframalpha.pmxbot.wa(None, None, None, None, rest=query)
assert res == '2.205 lb (pounds)'