/**
 * Copyright (C) 2014-2015 Philip Helger (www.helger.com)
 * philip[at]helger[dot]com
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *         http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.helger.photon.uicore.html.swf;

import static org.junit.Assert.assertNotNull;

import org.junit.Test;

import com.helger.commons.microdom.IMicroNode;
import com.helger.commons.microdom.serialize.MicroWriter;
import com.helger.commons.url.SimpleURL;
import com.helger.html.hc.render.HCRenderer;

/**
 * Test class for class {@link HCSWFObject}.
 *
 * @author Philip Helger
 */
public final class HCSWFObjectTest
{
  @Test
  public void testCodeGen ()
  {
    final HCSWFObject x = new HCSWFObject ();
    x.setID ("div1");
    x.setSWFURL (new SimpleURL ("a.swf"));
    x.setWidth (500).setHeight (300);
    x.setRequiredSWFVersion ("9.0.0");
    x.addFlashVar ("flash1", "Wert");
    final IMicroNode aNode = HCRenderer.getAsNode (x);
    assertNotNull (aNode);
    if (false)
      System.out.println (MicroWriter.getXMLString (aNode));
  }
}

@@ -757,20 +757,76 @@
 g.junit.
-Test
+Rule;%0Aimport org.junit.Test;%0Aimport org.junit.rules.TestRule
 ;%0A%0Aimpor
@@ -1010,16 +1010,71 @@
 enderer;
+%0Aimport com.helger.photon.core.mock.PhotonCoreTestRule;
 %0A%0A/**%0A *
@@ -1185,16 +1185,86 @@
 tTest%0A%7B%0A
+  @Rule%0A  public final TestRule m_aRule = new PhotonCoreTestRule ();%0A%0A
   @Test%0A
@@ -1346,30 +1346,8 @@
 ();%0A
-    x.setID (%22div1%22);%0A
     

Test fix