Code Monkey home page Code Monkey logo

Comments (6)

david1hyman avatar david1hyman commented on June 15, 2024 1

Plus 1 on this issue. I ran into it a few weeks ago - just before this bug was posted - and I've been tinkering off and on in the hope that it was an implementation error; yesterday I proved it was not. Glad to see I'm not alone. I discovered the issue when I started using Cucumber Studio; it exports features with the quotes included.
@Tyler-Keith-Thompson over the next few days I might have a chance to try to fix this. If you have a solid idea of where the issue is you could point me to it. I'm sure I can track it down but I haven't looked yet at all.

In the meantime I made a run script that strips the quotes. I'd be happy to share if anyone is interested and willing to pardon my hacky bash.

from cucumberswift.

Tyler-Keith-Thompson avatar Tyler-Keith-Thompson commented on June 15, 2024 1

🎉 CucumberSwift v4.2.1 (running in the pipeline as I write this) should solve this problem. There are now 2 lexers, one that tokenizes for stub generation and one that parses Gherkin. The one that parses Gherkin no longer cares about integers or strings (but still cares about doc strings).

from cucumberswift.

Tyler-Keith-Thompson avatar Tyler-Keith-Thompson commented on June 15, 2024

Ahh, the lexer did that because it was trying to make it reasonable to generate step stubs with appropriate regular expressions. This was an oversight.

I'll add it to the backlog as a bug.

from cucumberswift.

Tyler-Keith-Thompson avatar Tyler-Keith-Thompson commented on June 15, 2024

So the trick here will be to remove the tokenization of string/Int from the lexer.

However, we should add a new lexer that tokenizes steps looking for string/Int for stub generation.

The implementation went the wrong direction when I tried to tokenize for stub generation and Gherkin simultaneously.

However, we now have consumers depending on the current implementation, so we should do another major version rev and either as part of this, or as a fast follow allow # to be escaped.

from cucumberswift.

david1hyman avatar david1hyman commented on June 15, 2024

Based on your description the chances of me tackling this issue feel pretty slim. As much as I'd love to I don't think I have the time to gain the domain understanding to work through it in a reasonable way. I'll be watching for an update and we wil test when it's available.

from cucumberswift.

Tyler-Keith-Thompson avatar Tyler-Keith-Thompson commented on June 15, 2024

I'll try and take a look at this in the near future. Things will finally have slowed down a bit for me by this weekend (unless the universe decides to punish me for predicting the future just there).

from cucumberswift.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.