using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;
using TechTalk.SpecFlow;

namespace Tests1
{
    [Binding]
    public class StepDefinition1
    {
        // For additional details on SpecFlow step definitions see http://go.specflow.org/doc-stepdef
        string word1;
        string word2;
        int dist;

        [Given("слово 1 это (.*)")]
        public void GivenWord1(string word)
        {
            this.word1 = word;
        }

        [Given("слово 2 это (.*)")]
        public void GivenWord2(string word)
        {
            this.word2 = word;
        }


        [When("расстояние")]
        public void Distance()
        {
            //TODO: implement act (action) logic
            EditDistance d = new EditDistance();
            this.dist = d.Distance(word1, word2);
            
        }

        [Then("результат должен быть (.*)")]
        public void ThenTheResultShouldBe(int result)
        {
            //TODO: implement assert (verification) logic

            Assert.AreEqual(this.dist, result);
        }
    }
}
