@@ -0,0 +1,2365 @@
+package org.musetest.selenium.values;%0A%0Aimport org.musetest.builtins.value.*;%0Aimport org.musetest.core.*;%0Aimport org.musetest.core.events.*;%0Aimport org.musetest.core.resource.*;%0Aimport org.musetest.core.values.*;%0Aimport org.musetest.core.values.descriptor.*;%0Aimport org.musetest.selenium.*;%0Aimport org.openqa.selenium.*;%0A%0A/**%0A * @author Christopher L Merrill (see LICENSE.txt for license details)%0A */%0A@MuseTypeId(%22dialog-text%22)%0A@MuseValueSourceName(%22Dialog Text%22)%0A@MuseValueSourceTypeGroup(%22Selenium.Dialog%22)%0A@MuseValueSourceShortDescription(%22Returns the dialog text.%22)%0A@MuseValueSourceLongDescription(%22Returns the text content of the currently-active modal dialog (a.k.a. Javascript Alert)%22)%0A@MuseStringExpressionSupportImplementation(DialogTextSource.StringExpressionSupport.class)%0A@SuppressWarnings(%22unused%22)  // instantiated via reflection%0Apublic class DialogTextSource extends BaseSeleniumValueSource%0A    %7B%0A    @SuppressWarnings(%22unused%22)  // used via reflection%0A    public DialogTextSource(ValueSourceConfiguration config, MuseProject project) throws MuseInstantiationException%0A        %7B%0A        super(config, project);%0A        %7D%0A%0A    @Override%0A    public String resolveValue(MuseExecutionContext context) throws ValueSourceResolutionError%0A        %7B%0A        try%0A            %7B%0A            Alert alert = getDriver(context).switchTo().alert();%0A            return alert.getText();%0A            %7D%0A        catch (NoAlertPresentException e)%0A            %7B%0A            throw new ValueSourceResolutionError(%22No alert is present%22);%0A            %7D%0A        %7D%0A%0A    @Override%0A    public String getDescription()%0A        %7B%0A        return %22alertText()%22;%0A        %7D%0A%0A    public final static String TYPE_ID = DialogTextSource.class.getAnnotation(MuseTypeId.class).value();%0A%0A    public static class StringExpressionSupport extends BaseArgumentedValueSourceStringSupport%0A        %7B%0A        @Override%0A        public String getName()%0A            %7B%0A            return %22alertText%22;%0A            %7D%0A%0A        @Override%0A        protected int getNumberArguments()%0A            %7B%0A            return 0;%0A            %7D%0A%0A        @Override%0A        protected String getTypeId()%0A            %7B%0A            return DialogTextSource.TYPE_ID;%0A            %7D%0A%0A        @Override%0A        protected boolean storeSingleArgumentAsSingleSubsource()%0A            %7B%0A            return true;%0A            %7D%0A        %7D%0A    %7D%0A

add DialogTextSource