Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make sure that each scenario gets a separate temp-dir #66

Open
josteinaj opened this issue May 31, 2018 · 0 comments
Open

Make sure that each scenario gets a separate temp-dir #66

josteinaj opened this issue May 31, 2018 · 0 comments

Comments

@josteinaj
Copy link
Member

josteinaj commented May 31, 2018

This was originally the intention, but I never got around to fixing it as it wasn't critical. Is there a use-case for not using separate temp-dirs?

Currently we need to repeat the directory paths in each scenario, which is kind of annoying:

<x:scenario label="_">
    
    <x:call step="my:script">
        <x:option name="some-option" select="..."/>
    </x:call>
    
    <x:scenario label="scenario 1">
        <x:call>
            <x:option name="result-dir" select="resolve-uri('1/result-dir',$temp-dir)"/>
            <x:option name="some-other-option" select="..."/>
        </x:call>
        <x:context>...</x:context>
        <x:expect>...</x:expect>
    </x:scenario>
    
    <x:scenario label="scenario 2">
        <x:call>
            <x:option name="result-dir" select="resolve-uri('2/result-dir',$temp-dir)"/>
        </x:call>
        <x:context>...</x:context>
        <x:expect>...</x:expect>
    </x:scenario>
    
</x:scenario>

Ideally we should be able to just set this at the top-level scenario, and then each sub-scenario can inherit this and still get separate temp-dirs:

<x:scenario label="_">
    
    <x:call step="my:script">
        <x:option name="result-dir" select="resolve-uri('result-dir',$temp-dir)"/>
        <x:option name="some-option" select="..."/>
    </x:call>

    <x:scenario label="scenario 1">
        <x:call>
            <x:option name="some-other-option" select="..."/>
        </x:call>
        <x:context>...</x:context>
        <x:expect>...</x:expect>
    </x:scenario>

    <x:scenario label="scenario 2">
        <x:context>...</x:context>
        <x:expect>...</x:expect>
    </x:scenario>

</x:scenario>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant