Sha256: 6b64b850847dadc5534d82919104da5cecdf2aa2e7c5615565fb0eb3f0d35641
Contents?: true
Size: 1.56 KB
Versions: 1
Compression:
Stored size: 1.56 KB
Contents
require 'spec_helper' module MavenPom describe Pom do let(:pom_module) { Pom.new fixture("pom.xml"), "some/pom/path/pom.xml" } let(:war_module) { Pom.new fixture("war.xml"), "some/war/path/pom.xml" } let(:child_module) { Pom.new fixture("child.xml"), "some/child/path/pom.xml" } it "knows the module's packaging" do pom_module.packaging.should == 'pom' war_module.packaging.should == 'war' end it "knows the module's dependencies" do pom_module.dependencies.should == [ "com.example:example-dep-1", "com.example:example-dep-2" # uses ${project.groupId} ] end it "knows the module's parent" do child_module.parent.should == pom_module.key child_module.parent_pom.should == pom_module end it "knows the module's build plugins" do child_module.build_plugins.should == [ "org.apache.maven.plugins:maven-source-plugin", "org.apache.maven.plugins:maven-javadoc-plugin", "org.apache.maven.plugins:maven-deploy-plugin" ] end it "knows the group_id and artifact_id" do war_module.group_id.should == "com.example" war_module.artifact_id.should == "example-war" end it "finds the parent's group_id if none is specified" do child_module.group_id.should == "com.example" child_module.artifact_id.should == "child" end it "has a key" do war_module.key.should == "com.example:example-war" end it "can get the pom's properties" do pom_module.properties.should == {'version.jdk' => '1.7'} end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
maven_pom-0.0.2 | spec/pom_spec.rb |