#268 Have you considered a port of Rspec (Fspec)?

javelinBCD Fri 27 Jun 2008

Have you considered a port of rspec to FAN? If you aren't aware they have developed a very sweet English user story runner for acceptance testing. It now has story level and specification level testing.

I am not a Ruby developer (I use it for prototyping design ideas). However I really like where RSpec has been taken.

I am new to Fan, but I like the potential.

PS. I also hope you create your own DSL for UI/Webpage layout and development. I like the Microsoft XAML/WPF/Silverlight, but it really should have been a DSL not a collage of stuff.

brian Fri 27 Jun 2008

Have you considered a port of rspec to FAN?

I don't think that is something Andy or I would do, given the huge lists of things we need for a 1.0 release. Although I'm hoping cool projects like that start happening. Eventually I'd like to have something like CPAN and RubyGems for bringing everything together.

I also hope you create your own DSL for UI/Webpage layout and development. I like the Microsoft XAML/WPF/Silverlight, but it really should have been a DSL not a collage of stuff

Microsoft needed XAML because C# isn't a very good declarative language (same reason Java always uses XML). One of the key features of Fan is that it is designed to write purely declarative stuff in a friendly format. In my experience most DSLs are just a way to express declarative information, so that is handled well by Fan. The really cool thing is that readObj and writeObj use the exact same format for serialization - so you can separate your declaration from code, or mix them just as easily.

helium Sat 28 Jun 2008

Some C#:

var panel = new Panel()
{
    Dock = DockStyle.Fill
};
panel.Controls.AddRange(new Control[] {
    new Button() { 
        Text = "Test button",
        Location = new Point(40, 50),
        Size = new Size(100, 30)                 
    },
    new Label() {
        Text = "Test label",
        Location = new Point(40, 100),                  
    }                
});

Not perfect, but not terrible also. I think it is more about multi language support. Using XAML you can have one design programm and use the result in C#, F#, VB.Net, C++/CLI and all the other .Net languages. You can even have designer with very little programming knowledge designing your UI. (I don't know if that would realy work.)

In Fan hte code above would look like this:

panel := Panel
{
    Dock = DockStyle.Fill

    Button { 
        Text = "Test button"
        Location = Point { X = 40; Y = 50 }
        Size = Size { Width = 100; Height = 30 }                 
    }
    Label {
        Text = "Test label"
        Location = Point{ X = 40; Y = 100}                  
    }                
}

Login or Signup to reply.