# Path: rwslib/extras/rwscmd/rwscmd.py
# GET_DATA_DATASET = 'rwscmd_getdata.odm'
#     VALID_DATASET_FORMATS = ("odm")
# class GetDataConfigurableDataset(ConfigurableDatasetRequest):
#     def __init__(self, dataset, study, environment, subject, params=None):
# def rws(ctx, url, username, password, raw, verbose, output, virtual_dir):
# def get_data(ctx, study, environment, subject):
# def rws_call(ctx, method, default_attr=None):
# def version(ctx):
# def data(ctx, path):
# def post(ctx, odm):
# def metadata(ctx, drafts, path):
# def direct(ctx, path):
# def autofill(ctx, steps, metadata, fixed, study, environment, subject):


import unittest
import httpretty
from click.testing import CliRunner
from rwslib.extras.rwscmd import rwscmd
# -*- coding: utf-8 -*-

__author__ = 'anewbigging'





class TestRWSCMD(unittest.TestCase):
    def setUp(self):
        self.runner = CliRunner()

    @httpretty.activate
    def test_version(self):
        httpretty.register_uri(
            httpretty.GET, "https://innovate.mdsol.com/RaveWebServices/version",
            status=200,
            body='1.0.0')


# Path: rwslib/extras/rwscmd/rwscmd.py
# GET_DATA_DATASET = 'rwscmd_getdata.odm'
#     VALID_DATASET_FORMATS = ("odm")
# class GetDataConfigurableDataset(ConfigurableDatasetRequest):
#     def __init__(self, dataset, study, environment, subject, params=None):
# def rws(ctx, url, username, password, raw, verbose, output, virtual_dir):
# def get_data(ctx, study, environment, subject):
# def rws_call(ctx, method, default_attr=None):
# def version(ctx):
# def data(ctx, path):
# def post(ctx, odm):
# def metadata(ctx, drafts, path):
# def direct(ctx, path):
# def autofill(ctx, steps, metadata, fixed, study, environment, subject):


# Path: rwslib/tests/test_rwscmd.py
import unittest
import httpretty
from click.testing import CliRunner
from rwslib.extras.rwscmd import rwscmd

# -*- coding: utf-8 -*-

__author__ = 'anewbigging'





class TestRWSCMD(unittest.TestCase):
    def setUp(self):
        self.runner = CliRunner()

    @httpretty.activate
    def test_version(self):
        httpretty.register_uri(
            httpretty.GET, "https://innovate.mdsol.com/RaveWebServices/version",
            status=200,
            body='1.0.0')


        result = self.runner.invoke(rwscmd.rws, ['https://innovate.mdsol.com', 'version'], input="\n\n")