robotcode icon indicating copy to clipboard operation
robotcode copied to clipboard

[ENHANCEMENT] better Literal support

Open WisniewskiP opened this issue 1 year ago • 0 comments

Is your enhancement request related to a problem? Please describe. when keyword has Literal as argument I would like to have value suggestions when writing test. example: Library:

from typing import Literal

def keyword_with_literals(arg1: Literal["v1", "v2"]):
    pass

test:

*** Settings ***
Library    literals.py

*** Test Cases ***
Test
    Keyword With Literals  arg1=v1

current suggestions are random strings: grafik

Describe the solution you'd like the list should only contain values from literal

Additional context tested with:

> robot --version
Robot Framework 7.0 (Python 3.10.1 on win32)

WisniewskiP avatar Feb 02 '24 10:02 WisniewskiP