You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@isis.apache.org by Stephen Cameron <st...@gmail.com> on 2018/04/03 07:05:07 UTC

Fixtures location

Hi,

I've a small project based on SimpleApp archetype.

I want to present a list of fixtures in the Prototype menu, but am having
trouble reconfiguring.

I change the default fixture specification provider class as follows:

/**
 * Specifies where to find fixtures, and other settings.
 */
@DomainService(
        nature = NatureOfService.DOMAIN
)
public class DomainAppFixtureScriptsSpecificationProvider implements
FixtureScriptsSpecificationProvider {
    public FixtureScriptsSpecification getSpecification() {
        return FixtureScriptsSpecification

.builder(/*DomainAppFixtureScriptsSpecificationProvider.class*/
"au.com.scds.eventschedule.fixture")
                .with(FixtureScripts.MultipleExecutionStrategy.EXECUTE)
                //.withRunScriptDefault(DomainAppDemo.class)

.withRunScriptDropDown(FixtureScriptsSpecification.DropDownPolicy.CHOICES)
                .withRecreate(/*DomainAppDemo.class*/
CreateScheduledEvents.class)
                .build();
    }

}

Then when I go to the menu item Prototyping > Run Fixture Script its
disabled and a message telling me there are no fixture scripts under the
package " au.com.scds.eventschedule.fixture" is visible. This is incorrect
there are 4 scripts.

Maybe it needs a Module to have included that package too?

Re: Fixtures location

Posted by Stephen Cameron <st...@gmail.com>.
Yes, it does need a Module to include that package

On Tue, Apr 3, 2018 at 5:05 PM, Stephen Cameron <st...@gmail.com>
wrote:

> Hi,
>
> I've a small project based on SimpleApp archetype.
>
> I want to present a list of fixtures in the Prototype menu, but am having
> trouble reconfiguring.
>
> I change the default fixture specification provider class as follows:
>
> /**
>  * Specifies where to find fixtures, and other settings.
>  */
> @DomainService(
>         nature = NatureOfService.DOMAIN
> )
> public class DomainAppFixtureScriptsSpecificationProvider implements
> FixtureScriptsSpecificationProvider {
>     public FixtureScriptsSpecification getSpecification() {
>         return FixtureScriptsSpecification
>                 .builder(/*DomainAppFixtureScriptsSpecificationProvider.class*/
> "au.com.scds.eventschedule.fixture")
>                 .with(FixtureScripts.MultipleExecutionStrategy.EXECUTE)
>                 //.withRunScriptDefault(DomainAppDemo.class)
>                 .withRunScriptDropDown(FixtureScriptsSpecification.
> DropDownPolicy.CHOICES)
>                 .withRecreate(/*DomainAppDemo.class*/
> CreateScheduledEvents.class)
>                 .build();
>     }
>
> }
>
> Then when I go to the menu item Prototyping > Run Fixture Script its
> disabled and a message telling me there are no fixture scripts under the
> package " au.com.scds.eventschedule.fixture" is visible. This is
> incorrect there are 4 scripts.
>
> Maybe it needs a Module to have included that package too?
>
>
>
>
>