Bug 152543 [DataBinding] ValueBinding NPE when update target from model is false
When a ValueBinding is constructed and instructed not to update the target from the model via the BindSpec a NPE is thrown when it tries to access the modelToTargetConverter. Exception in thread "main" java.lang.NullPointerException at org.eclipse.jface.internal.databinding.internal.ValueBinding.doUpdateTargetFromModel(ValueBinding.java:268) at org.eclipse.jface.internal.databinding.internal.ValueBinding.updateTargetFromModel(ValueBinding.java:250) at org.eclipse.jface.internal.databinding.internal.ValueBinding.<init>(ValueBinding.java:112) at Snippet.main(Snippet.java:32) Attaching patch...
tests/org.eclipse.jface.tests.databinding/src/org/eclipse/jface/tests/databinding/BindingTestSuite.java
* http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *     Brad Reynolds - bug 137877
 *******************************************************************************/
package org.eclipse.jface.tests.databinding;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
import org.eclipse.jface.internal.databinding.provisional.conversion.IdentityConverterTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryBooleanPrimitiveTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryBytePrimitiveTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryDoublePrimitiveTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryFloatPrimitiveTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryIntTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryLongPrimitiveTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryShortPrimitiveTest;
import org.eclipse.jface.internal.databinding.provisional.factories.DefaultBindSupportFactoryTest;
import org.eclipse.jface.internal.databinding.provisional.validation.ObjectToPrimitiveValidatorTest;
import org.eclipse.jface.tests.databinding.mask.EditMaskLexerAndTokenTest;
import org.eclipse.jface.tests.databinding.observable.value.WritableValueTest;
import org.eclipse.jface.tests.databinding.scenarios.BindingScenariosTestSuite;
import org.eclipse.jface.tests.databinding.util.MocksTest;
import org.eclipse.jface.tests.examples.model.PersonTests;
import org.eclipse.jface.tests.internal.databinding.internal.viewers.SVOCWLTest;
import org.eclipse.jface.tests.internal.databinding.internal.viewers.SelectionProviderSingleSelectionObservableValueTest;
import org.eclipse.jface.tests.internal.databinding.provisional.observable.AbstractObservableTest;
import org.eclipse.jface.tests.internal.databinding.provisional.viewers.ViewersObservableFactoryTest;
public class BindingTestSuite extends TestSuite {