ruby-yasm 0.2.1 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.github/workflows/ruby.yml +31 -0
- data/.gitignore +5 -3
- data/ChangeLog.md +13 -1
- data/Gemfile +17 -0
- data/LICENSE.txt +1 -1
- data/README.md +48 -27
- data/Rakefile +6 -32
- data/gemspec.yml +3 -5
- data/lib/yasm/command.rb +274 -0
- data/lib/yasm/program.rb +31 -25
- data/lib/yasm/version.rb +3 -1
- data/lib/yasm.rb +3 -2
- data/ruby-yasm.gemspec +36 -86
- data/spec/command_spec.rb +91 -0
- data/spec/program_spec.rb +89 -10
- data/spec/spec_helper.rb +2 -3
- data/spec/yasm_spec.rb +1 -1
- metadata +30 -71
- data/.gemtest +0 -0
- data/lib/yasm/task.rb +0 -153
- data/spec/task_spec.rb +0 -70
data/spec/task_spec.rb
DELETED
@@ -1,70 +0,0 @@
|
|
1
|
-
require 'yasm/task'
|
2
|
-
|
3
|
-
require 'spec_helper'
|
4
|
-
|
5
|
-
describe Task do
|
6
|
-
it "should support a :target option" do
|
7
|
-
task = Task.new(:target => :amd64)
|
8
|
-
|
9
|
-
task.arch.should == :x86
|
10
|
-
task.machine.should == :amd64
|
11
|
-
end
|
12
|
-
|
13
|
-
describe "target!" do
|
14
|
-
it "should return true for valid targets" do
|
15
|
-
task = Task.new
|
16
|
-
|
17
|
-
task.target!(:amd64).should == true
|
18
|
-
end
|
19
|
-
|
20
|
-
it "should raise ArgumentError when passed unknown targets" do
|
21
|
-
task = Task.new
|
22
|
-
|
23
|
-
lambda {
|
24
|
-
task.target! :lol
|
25
|
-
}.should raise_error(ArgumentError)
|
26
|
-
end
|
27
|
-
|
28
|
-
describe "x86" do
|
29
|
-
subject do
|
30
|
-
Task.new { |task| task.target! :x86 }
|
31
|
-
end
|
32
|
-
|
33
|
-
it "should set the arch value" do
|
34
|
-
subject.arch.should == :x86
|
35
|
-
end
|
36
|
-
|
37
|
-
it "should set the machine value" do
|
38
|
-
subject.machine.should == :x86
|
39
|
-
end
|
40
|
-
end
|
41
|
-
|
42
|
-
describe "amd64" do
|
43
|
-
subject do
|
44
|
-
Task.new { |task| task.target! :amd64 }
|
45
|
-
end
|
46
|
-
|
47
|
-
it "should set the arch value" do
|
48
|
-
subject.arch.should == :x86
|
49
|
-
end
|
50
|
-
|
51
|
-
it "should set the machine value" do
|
52
|
-
subject.machine.should == :amd64
|
53
|
-
end
|
54
|
-
end
|
55
|
-
|
56
|
-
describe "lc3b" do
|
57
|
-
subject do
|
58
|
-
Task.new { |task| task.target! :lc3b }
|
59
|
-
end
|
60
|
-
|
61
|
-
it "should set the arch value" do
|
62
|
-
subject.arch.should == :lc3b
|
63
|
-
end
|
64
|
-
|
65
|
-
it "should set the machine value" do
|
66
|
-
subject.machine.should == :lc3b
|
67
|
-
end
|
68
|
-
end
|
69
|
-
end
|
70
|
-
end
|